f2c/libf2c

Michael Schwendt bugs.michael at gmx.net
Wed Dec 21 11:23:54 UTC 2005


On Mon, 19 Dec 2005 18:16:37 -0800, Michael A. Peters wrote:

> On Tue, 2005-12-20 at 01:04 +0000, Paul wrote:
> > Hi,
> > 
> > I'm considering packaging f2c and libf2c for extras, but have a couple
> > of questions.
> > 
> > First, neither has a configure file, just copy the makefile.u to
> > makefile and alter the odd parameter inside (libf2c). Am I okay to copy
> > the file from within the spec file and then run a patch against it?
> 
> I haven't seen the Makefile
> It would be better imho to modify the Makefile with sed so that macros
> can be used - IE
> 
> cp Makefile Makefile.orig
> cat Makefile.orig |sed -e s?"^PREFIX=stuff"?"PREFIX=%{_prefix}" or
> whatever.

Maybe, maybe not. ;) If the Makefile template ever changes in a way that
would require different substitutions, the sed commands will fail
silently. On the contrary, the patch will likely be rejected, causing the
build to fail, which will tell you that you need to revisit the Makefile
in order to create a new patch.  If, however, you verify your
substitutions everytime you do a version upgrade in your packages, using
sed -i or perl -i can be a time-saver, albeit with the risk of breaking
unexpectedly.




More information about the fedora-extras-list mailing list