Re: Configure options



>> On Sun, 2011-05-01 at 08:32 -0400, Super Bisquit wrote:
>> > Is it possible to add a none option to the --with-distro when
>> > building.

This patch (for a previous version of cross linux from scratch) could give you
an idea on where you would need to hack to add this option:
http://svn.cross-lfs.org/svn/repos/patches/NetworkManager/NetworkManager-0.7.2-clfs_support-1.patch
(it is pretty short).

Mind you, --with-distro=none is not --with-linux=none, it won't
disable the "linuxisms"
because without them NetworkManager just won't work right now.

Which means in practice that even with --distro=none you wouldn't be
able to even build
NM in FreeBSD.

>> > Let me at least try to make it work while everybody is waiting for the
>> > project to be finished. I have a laptop with the iwi|ipw2100/2200
>> > radio.
>>
>> At the moment NM is Linux-only, mainly due to usage of
>> Linux-kernel-specific WiFi and Ethernet calls, hardware detection using
>> udev, and IP/routing using netlink.
>
> What does netlink do? There may be a port of a similar application in the
> ports tree.

netlink is not an application but a protocol (RFC 3549) between the kernel
and userspace.

>>  While NM could be ported, somebody
>> would have to explore the FreeBSD alternatives to stuff like udev
> I've mentioned devd.

You (or the other person doing the port) will probably have to write
nm-devd-manager.c to do what nm-udev-manager.c does, then.

>> , and programmatically setting IP addresses and
>> routes.
>
> See the manpages for each driver and for ifconfig.

If NM would have to do different things for different drivers,
that's not so nice. They need to support a common way to
get/set essential info, like what is done in Linux.

> Anyway, having the option of none for --with-distro would make it easier for
> the person doing the google project, myself, and others to be able to start
> working on porting. It won't hurt the build process. The gnome network
> manager team would see the changes and can work them into the code.

Instead of --with-distro=none (that probably won't help at all), why not
add --with-distro=freebsd (based on the patch shown above).

You can implement the FreeBSD backend (like the one for paldo linux
shown in the patch) and a FreeBSD-specific settings plugin (like the ifcfg
for redhat or ifupdown for debian) to get NM to recognize the already
setup network devices from system config file(s).

Then you can write nm-devd-manager.c to replace nm-udev-manager.c
for device detection etc (and disable udev at configure-time when
distro==freebsd).

Finally you can replace netlink stuff with freebsd-specific things as
a "quick & dirty" hack to see how much work would be needed to
get things done "properly".

(netlink usage seems to be limited to
nm-netlink-monitor.{c,h}
and
nm-system.c
In NetworkManager.)

With these changes you would get a FreeBSD version of NM that
might be even semi-usable, although I know nothing about FreeBSD
and very few things about NM so I might well be wrong in my
assessment.

Cheers,
Pantelis


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]