gEDA-dev: Building gEDA

Stuart Brorson sdb at cloud9.net
Fri Jul 28 13:08:13 EDT 2006


>>> Small issues with the build:: libgeda must be installed under /usr/
>>> whatever before the rest will compile. This is a pain, and could
>>> probably be improved.
>>
>> Umm, actually it doesn't.  You just need to set the $LD_LIBRARY_PATH.
>> If you just say "make", then the Makefile tells you what to do.
>> Below find the spew from "make" which I get.  Note that I generally
>> build in an arbitrary directory and install into /usr/local/geda.
>> However, you can install anywhere.
>>
>> Stuart
>
> I've been doing that for all my local compiles. What I'm now trying to
> do, is compile with a prefix of /usr/, but _install_ into a build root
> somewhere else.
>
> Is it OK to set the LD_LIBRARY_PATH etc.. to "built_root/lib", then
> finish compiling gschem, gattrib etc...?

Hmmm, OK, you are exceeding the limits of my knowledge.  However, I
suspect the problem may stem from the GNU buils system, and not from
gEDA.

One thing about how gEDA's base Makefile works:  All it does is cd
into each source directory in turn and then run the appropriate make
stuff in there.  The make stuff in each source directory is the
classical GNU configure.ac, Makefile.am, etc.  The GNU stuff is likely
more flexible in terms of install targes than gEDA base Makefile.
Perhaps you can bypass the base Makefile with your 
own shell (or Perl) script which issues the right commands to do what
you want.  FWIW, my CD Installer does just that.  Take a look at it.

> If the build picks up libgeda's .pc file from the build-root, it will
> get -L... -I... compile flags which point to /usr/... not the build root
> IIRC.
>
> For the moment, I have given up and just installed libgeda directly
> in /usr/.. as well as my build-root directory. Whilst this would mess up
> any existing libgeda on the system, this is only a sacrificial build
> environment anyway.
>
> Am I doing this in a stupid way?

I'm not smart enough to know.  ;-)  I don't really understand why you
want to build in one directory, and then move the installed stuff into
another.   Maybe you need to do something like:

./configure --prefix=/first/install/dir
make
make install
<check that everything is OK>
./configure --prefix=/final/install/dir
make
make install

DO this in each source directory (i.e. not in teh geda/gaf dir).  It's
not elegant, but it seems to be what you want, right?

> As a side note, I was surprised to find that CVS is required gschem to
> autogen.sh correctly.. If I'm building on a system without CVS, it can't
> fetch it's "intl" directory. What exactly is it fetching at this point?

I think the idea is that only developers will use the autogen.sh
stuff, and developers are required to have more tools installed
(i.e. CVS) than the ordinary user.  The developers spin distribution
tarballs ("make dist") for the ordinary users which don't have the
whole set of tools.

Stuart


More information about the geda-dev mailing list