Eric H. Johnson on 11 Nov 2011 05:46:23 -0800


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

Re: [PLUG] Linux EMC and Headless Systems


Rich,

Sorry about the delay getting back to you given the amount of effort you put
into that post, which I appreciate. I can see that there might be some
advantages to using gentoo, but ultimately I would like it to get the
removal of these dependencies incorporated back into the main trunk of EMC,
which is Ubuntu based. Also while running on gentoo may solve the problem of
dependencies, I still need to generate the installable packages, which under
Ubuntu is done with debuild. While this is becoming increasingly out of
date, you can see that process here:

http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?EMC_With_Custom_Kernel

Note: Although it has been modified since, I wrote the original for this
wiki entry. SMP support was subsequently incorporated into the main trunk.

There have been several discussions on the mailing lists and chat sessions
to separate EMC into multiple packages, and in fact this has been partially
initiated. Usually they have talked about four separate packages consisting
of EMC core, device drivers, user interfaces, and I forget the fourth one.
Device drivers, especially the ones supporting FPGA based IO boards, are
already in their own packages. 

Regards,
Eric


There was some discussion after last night's meeting about getting
software to work on more minimal installs (no X11, etc).  The specific
software being discussed was linux EMC (used to control CNC machinery
in realtime).  Apparently the ubuntu packages for this tend to pull in
stuff which culminates in a system that ends up with stuff like gnome
and openoffice in order to control a CNC mill.  It seems kind of
bizarre but when one package uses one file out of some other package
these things can spiral out of control pretty easily.

I imagine that many of these principles could be applied to any
distro, but this is something Gentoo actually excels at with its USE
flag features.  When packages have optional features that tend to pull
in other dependencies the distro sets a default but then lets you
override it, setting one flag to switch these kinds of dependencies on
or off system-wide.  So, setting USE=-X can have a big impact on your
footprint (as long as you don't install something that just has to
have X installed).  When packages lack these flags and there is a real
use case for having them the maintainers tend to be sympathetic to
adding them.

Looking at the ebuild on
http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?EmcOnGentoo I don't
actually see anything being pulled in which would necessitate a server
actually running X11.  It will end up drawing in gtk+ and some X11
libraries, but that doesn't require you to actually run X (without
doing more testing I can't say whether it would end up pulling in an
X11 server or not).  So, my suspicion is that if their Ubuntu packages
are doing this either their dependencies aren't correct, or Ubuntu
lacks the ability to make the dependencies granular enough.

I think there is also a philisophical difference between Ubuntu and
Gentoo that may be at play.  When I have tinkered with Ubuntu I've
noticed that installing a package tends to configure it to run - if
you apt-get install gdm and reboot you end up with a gdm login screen.
 On Gentoo this is not the case - if you install GDM and reboot you
get a text console - you need to explicitly add it to your runlevels
for sysvinit in order to have it start.  I'm sure Ubuntu has some
standard way to make things not run, and perhaps getting your system
to be headless is just as simple as getting gdm to not run.  That
won't get openoffice off of your hard drive, but it will get X11 out
of your RAM.

Your other option is of course to repackage the software and
better-tune your dependencies.  You may find the ebuild on that page I
linked to useful if you do this since it is fairly human readable,
though you'd have to translate all the dependencies into the
appropriate ubuntu packages.  Or, of course, you could just run Gentoo
- it isn't a bad choice for projects like this.  :)

Rich
___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug