I fixed this in tree basically with your fix below. Basically these checks should always be done, not just in certain conditions. The problem with this is they have error messages right in the tags, so it will take a bit of rework that is probably not worth it.
Mike On Jan 19, 2010, at 10:54 AM, Eric Varsanyi wrote: > I'm building freeswitch RPM packages using the sipxecs build system and the > rpm packaging step was failing because libjs.so was not being built. After > some digging it looks to me like a dependency problem in the libjs autoconfig > setup. The patch below works around the issue but there's likely a better way. > > -Eric Varsanyi > > Details: > > The proximal issue is that EGREP is not defined when checking for the ability > to make shared libs. > > The problem is some sort of dependency issue between AC_CHECK_HEADER and > AC_PROG_LIBTOOL. > > It appears that using AC_CHECK_HEADER at 'autoconf' time remembers that the > check for, say, EGREP has been done and prevents it from being issued again > in the resulting configure script, however if AC_CHECK_HEADER is used in a > runtime 'if' block (the 'if' runs when configure runs, not autoconf) and that > if does not pay off AC_PROG_LIBTOOL ends up w/o EGREP defined and the check > if we can build a shared library fails (and thus no .so is built). > > A simple workaround is to move AC_PROG_LIBTOOL up above the AC_ARG_WITH([dso > ... check which uses AC_CHECK_HEADER in a bash if block (which does not pay > off on linux). I'm no autoconf wizard and my lame attempts to force it to > check for EGREP again failed -- it may be you're just not supposed to use > some things inside an 'if' block at 'configure' time. > > Index: libs/js/configure.ac > =================================================================== > --- libs/js/configure.ac (revision 16398) > +++ libs/js/configure.ac (working copy) > @@ -154,6 +154,8 @@ > CPPFLAGS="$CPPFLAGS -DJS_HAS_XML_SUPPORT=1" > fi > > +AC_PROG_LIBTOOL > + > dnl # configure option --with-dso > AC_ARG_WITH([dso], > AS_HELP_STRING([--with-dso], [build without DSO object (allows run-time > process extending)]), > @@ -229,8 +231,6 @@ > > with_tags="" > > -AC_PROG_LIBTOOL > - > AC_CONFIG_HEADERS(config.h) > AC_CONFIG_FILES([Makefile js.pc js-config.sh src/perlconnect/Makefile.PL]) > AC_OUTPUT > > > > _______________________________________________ > FreeSWITCH-dev mailing list > FreeSWITCH-dev@lists.freeswitch.org > http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev > UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev > http://www.freeswitch.org _______________________________________________ FreeSWITCH-dev mailing list FreeSWITCH-dev@lists.freeswitch.org http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev http://www.freeswitch.org