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

Re: how to patch configure.ac and not require autotools



On Sun, 2006-06-11 at 07:43 -0500, Rex Dieter wrote:
> Dan Horák wrote:
> > Hello,
> > 
> > I need to patch configure.ac so it doesn't explicitely add '-s' to
> > LDFLAGS (see
> > https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=194782). From a
> > discussion started in
> > http://www.redhat.com/archives/fedora-extras-list/2005-October/msg01545.html it is forbidden to use autotools during the build process and it suggests to patch configure and the other generated files too. But in my situation the only files that differ are configure.ac and configure. And after applying the patch their timestamps are set to the current time and because other files (Makefile.am, config.h, ...) depend on them, they want to be regenerated. The whole package seem buildable without the autotools, but with some not very nice messages about missing automake, autoconf, etc in the buildlog.
> 
> I guess I missed the conclusion that using auto* tools is absolutely
> forgidden.  AFAIK, it's not in the PackagingGuidelines, and there are
> certainly valid cases where their use is warranted (this may be one of
> them).  I'd suggest simply patching things and
> BuildRequires: automake autoconf
> and be done with it.

.. and wait for blindly generated diff to break your package. 


Pedantically speaking, the opposite is true. Modern automake-based
packages support and ship "missing":
c.f. /usr/share/automake-1.9/missing --help

I.e. the packager provides a *complete and functional* patch which
breaks timestamps on generated files, and does NOT to have the autotools
installed, the autotools will "touch the generated files", themselves

I.e. Actually, BuildConflicts: <autotools>
and using missing would solve the problem.


Less pedantically, if the default set of packages inside of the buildsys
doesn't contain the autotools, and if packagers were required to provide
complete patches, this issue becomes a non-issue. 

The down-side would be users rebuilding a package and having the
autotools installed, would see the autotools be run, i.e.
non-deterministic "user-builts".

Build qgit with the patch below and the autotools uninstalled to see the
effects I am talking about.

Ralf

--- qgit-1.3.orig/configure.ac	2006-06-04 09:50:57.000000000 +0200
+++ qgit-1.3/configure.ac	2006-06-11 12:09:05.000000000 +0200
@@ -17,7 +17,7 @@
 # Checks for libraries.
 gw_CHECK_QT
 CPPFLAGS="$CXXFLAGS $QT_CPPFLAGS"
-LDFLAGS="$LDFLAGS $QT_LDFLAGS -s"
+LDFLAGS="$LDFLAGS $QT_LDFLAGS"
 LIBS="$LIBS $QT_LIBS"
 
 # Checks for header files.
--- qgit-1.3.orig/configure	2006-06-04 09:51:06.000000000 +0200
+++ qgit-1.3/configure	2006-06-11 12:09:14.000000000 +0200
@@ -4682,7 +4682,7 @@
 
 
 CPPFLAGS="$CXXFLAGS $QT_CPPFLAGS"
-LDFLAGS="$LDFLAGS $QT_LDFLAGS -s"
+LDFLAGS="$LDFLAGS $QT_LDFLAGS"
 LIBS="$LIBS $QT_LIBS"
 
 # Checks for header files.

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