Re: Bug in configure




 Since, this hasn't been fixed in the 1.2.3, I repost this mail,
 should I CC: it to Owen Taylor?

-------------- Beginning of reposted message --------------------------------

  Hi,

  A friend of mine tried to compile gtk+-1.2.1 without installing glib-1.2.1.

glib-1.2.1 is well compiled in /usr/src/glib-1.2.1 but not installed, and
gtk+-1.2.1 was configured with: ./configure --with-glib=../glib-1.2.1

Then, during the compilation, he gets:

creating libgtk.la
(cd .libs && rm -f libgtk.la && ln -s ../libgtk.la libgtk.la)
gcc -DHAVE_CONFIG_H -I. -I. -I.. -DGTK_DISABLE_COMPAT_H -DG_LOG_DOMAIN=\"Gtk\"
 -DGTK_EXE_PREFIX=\"/usr/local\" -DGTK_DATA_PREFIX=\"/usr/local\"
 -DGTK_SYSCONFDIR=\"/usr/local/etc\"
 -DGTK_LOCALEDIR=\"/usr/local/share/locale\" -I.. -DGTK_NO_CHECK_CASTS
 -DUSE_XIM -I../../glib-1.2.1 -I../../glib-1.2.1/gmodule -I/usr/X11R6/include
 -g -O2 -Wall -c testgtk.c
/bin/sh ../libtool --mode=link gcc -g -O2 -Wall -o testgtk testgtk.o libgtk.la
 ../gdk/libgdk.la -L/usr/X11R6/lib -lXext -lX11 ../../glib-1.2.1/libglib.la
 ../../glib-1.2.1/gmodule.la -lm
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^ 
libtool: link: `../../glib-1.2.1/gmodule.la' is not a valid libtool archive
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^
make[2]: *** [testgtk] Error 1
make[2]: Leaving directory `/usr/src/gtk+-1.2.1/gtk'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/gtk+-1.2.1'
make: *** [all-recursive-am] Error 2

The error comes from ../../glib-1.2.1/gmodule.la should be really
../../glib-1.2.1/gmodule/gmodule.la

I guess this come from the line:
  GLIB_LIBS="$glib_dir/libglib.la $glib_dir/gmodule.la"
of the configure.in file which should be
  GLIB_LIBS="$glib_dir/libglib.la $glib_dir/gmodule/gmodule.la"
when configure is used with --with-glib=/The/path/of/non/installed/glib/

I guess this could be fixed by replacing:
-------------------------------------------------------------
# canonicalize relative paths
case $with_glib in
  /*)
    glib_dir=$with_glib
    ;;
  *)
    glib_dir="\$(top_builddir)/$with_glib"
    ;;
esac

GLIB_CFLAGS="-I$glib_dir -I$glib_dir/gmodule"
GLIB_LIBS="$glib_dir/libglib.la $glib_dir/gmodule.la"
GLIB_DEPLIBS=
--------------------------------------------------------------
in configure.in by:                                            
-------------------------------------------------------------
# canonicalize relative paths
case $with_glib in
  /*)
    glib_dir=$with_glib
    GLIB_LIBS="$glib_dir/libglib.la $glib_dir/gmodule/gmodule.la"
    ;;
  *)
    glib_dir="\$(top_builddir)/$with_glib"
    GLIB_LIBS="$glib_dir/libglib.la $glib_dir/gmodule.la"
    ;;
esac

GLIB_CFLAGS="-I$glib_dir -I$glib_dir/gmodule"
GLIB_DEPLIBS=
--------------------------------------------------------------

I am note sure about this, but this could apply to gthreads too.

                      DindinX

-------------- End of reposted message --------------------------------
-- 
David.Odin@bigfoot.com

Hope is a waking dream.
		-- Aristotle



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