Aaron Bostick <[EMAIL PROTECTED]> writes:

> This works in 2.0.  2.1 may be a little different.  You have to install
> these in this order on all machines to get the 'build' tool working:
> 
> openpkg
> make
> binutils
> gcc
> perl
> openpkg-tools

[snip]

> 
> If you have a lot of servers, you may want to have just one server
> compile them, then put the binary packages on an NFS share for the
> others to install from.  This helps solve a chicken and egg problem of
> compiling the compiling before your sandbox is ready.  For solaris, I
> had to grab the sunfreeware.com's binary gcc to get my build host
> bootstrapped.  If you installed the development stuff with Solaris, you
> may not have to do this.
> 
> Once that is done, you can then run commands like:
> 
> /opkg/bin/openpkg build ntp | /bin/sh -

It looks like this should work fine with a remote "ftp" archive just
with openpkg and openpkg-tools installed. However I had an issue with
the ftp connection to ftp.openpkg.org giving errors. I don't notice
this with other ftp sites so am unsure what the problem is (if any)
but had the same issue at the office too (to ftp://ftp.opengpkg.org).

Using an http mirror (specifically
http://ftp.ale.org/pub/mirrors/openpkg) resolved the problem so it
appears to be an "ftp issue" (not sure if my end or openpkg.org's).

> This will automagically find, build, and install ntp and its package
> dependencies in the proper order.  Its somewhere in between a Mandrake
> urpmi and gentoo's emerge IMO.

Yes, similar too to FreeBSD's ports system (but perhaps better
dependency checking?).

> Again, if you have a lot of servers, you will want to rsync nightly
> against the openpkg servers and then run your build commands against a
> local mirror.  It is much faster this way and saves bandwidth for C&W.

Yes, I imagine their servers are heavily loaded.  Using other mirrors is
probably a good idea too.

> The mirror command I use in cron is:
> 
> 0 0 * * * /opkg/bin/rsync -azv --exclude "BIN/" --exclude "ISO/"
> rsync://rsync.openpkg.org/openpkg-ftp/release/2.0/ /mirror/release/2.0/
> 
> If you have custom packages and need to rebuild your index then you can
> cron this as well:
> 
> 0 4 * * * /opkg/bin/openpkg index -c -r OpenPKG-2.0/Source/ -o
> /mirror/release/2.0/SRC/00INDEX.rdf.bz2 -i /mirror/release/2.0/SRC/
> 
> After you have your mirror setup, the build command above changes to:
> 
> /opkg/bin/openpkg build -f ftp://<your server
> name>/release/2.0/00INDEX.rdf ntp | /bin/sh -
> 
> You obviously also need to setup anonymous ftp on the mirror server.

Thanks for the pointers, though while I'm trying things out setting up
a mirror seems like overkill.

However I'd like to use this in the office where we have various
flavours of Linux, Solaris and AIX (does openpkg build on AIX or
should I just try?) and this is where I can see the advantage of
depending less on the underlying OS (which for certain applications
may not be changeable) and more on the "packaging system"
where you can guarantee common behaviour.

> I know it took me some time to figure these steps out so hopefully this
> will help you.

There's quite a bit of documentation about the first-time build
process which is good, but less about the "using it afterwards" which
is what I'm looking at now.  Certainly the /openpkg/bin/openpkg build
<package> facility is very nice after installing just 2 packages.

Thanks for the pointers I'll probably be using them soon if I can
convince my colleagues to take a look at this fine packaging system.

Simon
______________________________________________________________________
The OpenPKG Project                                    www.openpkg.org
User Communication List                      [EMAIL PROTECTED]

Reply via email to