On 02/22/2012 05:25 AM, Mr Dash Four wrote:

>>
>>     When running the package's ./install.sh script:
>>
>>     a) The setting for LIBEXEC is taken from the standard '_libexecdir'
>>        rpm macro.
>>   
> I am not sure (I am away and cannot check this at present), but I think 
> the "standard" rpm deployment has this already defined, along with a 
> host of other such directories, like %{_bindir}, %{_libdir} etc - it is 
> worth considering instead of introducing yet another variable.

_libexecdir *is* defined by RPM.

> 
>>     b) The setting for PERLLIB is taken from the standard
>>        'perl_sitelib' rpm macro.
>>   
> Again, I think this could also be determined/is already defined by rpm 
> itself - I'd be able to give you more definite answer later this evening 
> when I get home - I use the perl library directory macro in one of my 
> SELinux policy .spec files, so I need to look whether this is already 
> defined within rpm.

It is already defined within RPM. As I noted, however, the default
setting is distribution- and release-dependent so I override the default
in $HOME/.rpmmacros.

> 
>>     c) The setting for INITDIR is taken from the new
>>        'shorewall_initdir' rpm macro.
>>
>>     d) The setting for TARGET is taken from the new
>>        'shorewall_target' rpm macro.
>>   
> I take it the usage is either shorewall_initdir or INITDIR, but not both 
> (if not so, which one does take precedence?), right?

When running rpmbuild, %shorewall_initdir is the only way to specify the
directory containing the init scripts. Here is the text that invokes the
installer:

        DESTDIR=$RPM_BUILD_ROOT \
        OWNER=`id -n -u` \
        GROUP=`id -n -g` \
        LIBEXEC=%{_libexecdir} \
        PERLLIB=%{perl_sitelib} \
        INITDIR=%{shorewall_initdir} \
        TARGET=%{shorewall_target} \
        ./install.sh

Here's the %attr specification for the init script:

        %attr(0544,root,root) %{shorewall_initdir}/shorewall

> Would you be able to clarify the default directory layout of shorewall - 
> what component should be where (in which directory)? It would help me 
> better understand the reasons behind the chosen layout and your choice 
> of directories.

Because the installer has knowledge of the file hierarchy of a number of
distributions, 'default' is distribution-dependent. I think it would be
appropriate to document that on the web site; I'll work on that over the
next day or two.

-Tom
-- 
Tom Eastep        \ When I die, I want to go like my Grandfather who
Shoreline,         \ died peacefully in his sleep. Not screaming like
Washington, USA     \ all of the passengers in his car
http://shorewall.net \________________________________________________

Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Shorewall-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/shorewall-devel

Reply via email to