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

Re: missing filename in install.sh



Fix committed.  Discussion inline.

On Fri, Feb 26, 2010 at 9:50 PM, Adam Thompson <..hidden..> wrote:
> (Applies to all versions of install.sh in trunk, confirmed in SVN revs
> 799 through 2896.)
>
> Line 15 reads:
>> sed -i.orig "s|WORKING_DIR|$CWD|"
> which does nothing except spit out a warning message.
>
> INSTALL.manual instead lists the command:
>> sed -e "s|WORKING_DIR|$(pwd)|" ledgersmb-httpd.conf > ledgersmb-httpd-13.conf
>
> @sbts wants to keep the "sed -i.orig" form because of its atomicity in
> case of interruption [from IRC chat 2010-feb-26].
>

For the script, we will probably use sed -i.  This makes a difference
only in a few very specific cases (installing from svn where you
either have multiple installs per server, or want to commit).
Developers would do better to use the redirect.  General users will
probably get less confused with the inline....

> I'll point out that for building distro pkgs, it might be better if the
> MD5 hash of a file doesn't change, i.e. using the redirection form
> instead.

The RPM's tend to add everything to a known location beforehand and
tend to echo the config file to an appropriate directory.  This
command would not be run when installing from RPM.

I don't know about debian packages, but I understand the config stuff
there operates a bit differently.

>  If installing from source, it doesn't matter much one way or
> the other.  OTOH, in a pkg *sample* config files are usually stored
> under /usr/share/doc/* or something like that, and it's also possible to
> mark ledgersmb-httpd.conf as a config file so verification runs (e.g.
> rpm -V) don't bomb on it changing...

See above.  The ledgersmb-httpd.conf file isn't even stored in this
directory when generated by the script.


>
> So, then line 15 should probably be changed to:
>> sed -i.orig "s|WORKING_DIR|$CWD|" ledgersmb-httpd.conf
>
> I'm just getting my toes wet with this project, so I can't offer any
> concrete opinion on whether INSTALL.manual and install.sh should match
> more precisely, or which version should prevail.

Thanks for the bug report!

Best Wishes,
Chris Travers