ltib
[Top][All Lists]
Advanced

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

Re: [Ltib] Installing Part of a Package


From: Stuart Hughes
Subject: Re: [Ltib] Installing Part of a Package
Date: Tue, 16 Feb 2010 12:18:42 +0000
User-agent: Thunderbird 2.0.0.16 (X11/20080707)

Hi Mark,

You're on the right track.

The approaches I favour are:

1/ Create a sub-package of the main package.

For example, if you look at dist/lfs-5.1/coreutils you'll see there are
2 spec files, coreutils.spec and seq.spec.  seq.spec is just core utils,
but only installing a single utility.

2/ Add logic to the spec file to detect and build/install only the parts
you want.

For example take a look at dist/lfs-5.1/dropbear.spec, this has a bunch
of tests for varibles (PKG_DROPBEAR_WANT_URANDOM_DEV,
PKG_DROPBEAR_WANT_NO_REV_DNS) which can be used to turn on/off sections
(this is the easiest, but not the best example, dtc-common.tmpl is more
like that which you seek).


1/ Is the simplest to implement, but ugly in a way as it's inefficient
and could be confusing (where does xxxyyy come from).

2/ Is better, but more complex to implement as not only do you need to
instrument the .spec file, but you also need to add the appropriate
extra logic into config/userspace/packages.lkc.  Note that any config
symbols that include _WANT_ will automatically be exported for you (so
at least that's easier).

I would recommentd, if you have the time do 2/ otherwise 1/.

Regards, Stuart


Mark wrote:
> Hello
> 
> Could anybody recommend a sensible method of only installing part of a
> package? For example, some of the scenarios that I have been looking at
> recently are, installing only agetty from the util-linux package,
> installing only init from the sysvinit package and installing only the
> compiled terminfo definitions from the ncurses package.
> 
> My ideas so far include...
> 
> 1) Modifying the appropriate .spec file to change the install behaviour
> or add a post-install clean-up.
> 
> 2) Creating a platform specific .spec file to change the install
> behaviour or add a post-install clean-up.
> 
> 3) Adding a clean-up option to remove the unwanted files in the same way
> as the various non-NFS deployment options.
> 
> 4) Creating a new dummy package to build and install the subset of
> packages that I require.
> 
> Any comments or thoughts would be greatly appreciated.
> 
> Thanks
> 
> Mark
> 
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]