Re: Trouble with 20020715 snapshot

2002-07-17 Thread Alan DeKok

"Alexandre Strube" <[EMAIL PROTECTED]> wrote:
> Even worse. Now it dies faster >:-)

  Try the snapshot from last night.  (The 16'th)

  Alan DeKok.

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Trouble with 20020715 snapshot

2002-07-16 Thread Alexandre Strube

On Tue, 16 Jul 2002 17:17:04 +0200, [EMAIL PROTECTED] wrote:

Even worse. Now it dies faster >:-)

[root@unix ~/xxx/freeradius-snapshot-20020715]# make
gmake[1]: Entering directory `/root/porao/freeradius-snapshot-20020715'
Making all in libltdl...
gmake[2]: Entering directory `/root/porao/freeradius-snapshot-20020715/libltdl'
gmake[2]: *** No rule to make target `all'.  Stop.
gmake[2]: Leaving directory `/root/porao/freeradius-snapshot-20020715/libltdl'
gmake[1]: *** [common] Error 1
gmake[1]: Leaving directory `/root/porao/freeradius-snapshot-20020715'
make: *** [all] Error 2

>> I always compile the snapshots with the same configure options, which are
>> ./configure  --with-mysql-lib-dir=/usr/lib/mysql \
>> --with-mysql-include-dir=/usr/include/mysql \
>> --with-mysql-dir=/usr/bin --enable-ltdl-install=no \
>  The 'enable-ltdl-install=no' is most likely the problem.
>  If you don't have libltdl onyour system already, then the build
>won't find *any* ltdl.h, and will die.
>  Yeah, looking at your compile output, it's not finding any ltdl.h,
>or libltdl.h
>  Don't disable ltdl installation.




- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Re: Trouble with 20020715 snapshot

2002-07-16 Thread Ilguiz Latypov


Alan,

On Tue, 16 Jul 2002, Alan DeKok wrote:

>   My thoughts are that the patches are a nice idea, but there's no way
> I'm going to re-write the autoconf stuff just before 0.6.1 is
> released.

My patch is only a suggestion, and thanks for even paying any attention to 
it.

>   Also, I'm *never* going to willingly use automake.

I understand that one of the drawbacks of automake is its build rules
based on naming conventions.  This is difficult to comprehend.  On the
positive side, automake would probably help reduce areas for human errors.

Luckily, automake is not employed in radiusd tree and the patch didn't
introduce implicit automake rules.

I only wanted automake to create symlinks install-sh, mkinstalldirs and
missing.  It turns out the same can be achieved without adding 
AM_INIT_AUTOMAKE to configure.in.

>   So what, exactly, are the benefits of your patches?  Fixing some
> ltdl installation issues?  If so, why not supply a minimal patch to do
> just that?

The only benefit of the patch as I see is supposedly increased
portability of the radiusd build process.  I admit this is far from any 
reasonable application.

The configure scripts in subdirectories were not taken care of.

>   I'd rather see a series of small patches to add functionality
> piecemeal, than one large patch which changes everything, and adds a
> large number of new things.

Agree.

Ilguiz


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Re: Trouble with 20020715 snapshot

2002-07-16 Thread Alan DeKok

Ilguiz Latypov <[EMAIL PROTECTED]> wrote:
> I forgot to attach the new files:

  Large patches are probably better off on a web site, rather than
being posted to the mailing list.  And they should go to -devel,
rather than -users.


  My thoughts are that the patches are a nice idea, but there's no way
I'm going to re-write the autoconf stuff just before 0.6.1 is
released.

  Also, I'm *never* going to willingly use automake.

  So what, exactly, are the benefits of your patches?  Fixing some
ltdl installation issues?  If so, why not supply a minimal patch to do
just that?

  I'd rather see a series of small patches to add functionality
piecemeal, than one large patch which changes everything, and adds a
large number of new things.

  Alan DeKok.


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Re: Trouble with 20020715 snapshot

2002-07-16 Thread Alan DeKok

Ilguiz Latypov <[EMAIL PROTECTED]> wrote:
> The bootstrap script allows to remove automatically generated files from
> the CVS repository.  However, some constructs in the updated configure.in
> are valid only with the newer autoconf.  Perhaps, putting AC_PREREQ(2.53)  
> into configure.in could be a good precaution.

  Maybe.  I'd rather not force the use of the "latest and greatest"
tools, as that usually creates more problems than it solves.

> Another small problem was due to the sql_fetch_row() prototypes in 
...
> [ rlm_sql_postgresql and rlm_sql_unixodbc ]

  Hmm... I don't even understand why those functions aren't "static".
They should ALL be "static", and they shouldn't have prototypes in the
header file.

> not synchronized with their .c counterparts.  Does the patch included
> below fix those prototypes correctly?  Thank you,

  Yes, I've applied those patches, thanks.

> +AM_INIT_AUTOMAKE(radiusd, ${RADIUSD_VERSION})

  I *hate* automake.  It's a useless, insane, bloated piece of
garbage.  I've *never* found a case where using automake helped.  It's
always made the source harder to maintain, and reduced previously neat
Makefiles to opaque strings typed by dyslexic monkeys on acid.

  Alan DeKok.

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Re: Trouble with 20020715 snapshot

2002-07-16 Thread Ilguiz Latypov


On Tue, 16 Jul 2002, Ilguiz Latypov wrote:

> The bootstrap script allows to remove automatically generated files from
> the CVS repository.

I forgot to attach the new files:

   acinclude.m4

which is former aclocal.m4 without libtool.m4 and AC_CHECK_TYPE_INCLUDE 
and the

   bootstrap

script.

=
dnl See whether we need a declaration for a function.
dnl RADIUSD_NEED_DECLARATION(FUNCTION [, EXTRA-HEADER-FILES])
AC_DEFUN(RADIUSD_NEED_DECLARATION,
[AC_MSG_CHECKING([whether $1 must be declared])
AC_CACHE_VAL(radius_cv_decl_needed_$1,
[AC_TRY_COMPILE([
#include 
#include 
#ifdef HAVE_UNISTD_H
#include 
#endif
#ifdef HAVE_CRYPT_H
#include 
#endif
#ifdef HAVE_ERRNO_H
#include 
#endif
#ifdef HAVE_RESOURCE_H
#include 
#endif
#ifdef HAVE_GETOPT_H
#include 
#endif
#ifdef HAVE_MALLOC_H
#include 
#endif
#ifdef HAVE_UTMP_H
#include 
#endif
#ifdef HAVE_UTMPX_H
#include 
#endif
#ifdef HAVE_SYS_SELECT_H
#include 
#endif
#ifdef HAVE_DLFCN_H
#include 
#endif
#ifdef HAVE_REGEX_H
#include 
#endif
#ifdef HAVE_SYSLOG_H
#include 
#endif
#ifdef HAVE_INTTYPES_H
#include 
#endif
#ifdef HAVE_STDINT_H
#include 
#endif
#ifdef HAVE_ARPA_INET_H
#include 
#endif
$2],
[char *(*pfn) = (char *(*)) $1],
eval "radius_cv_decl_needed_$1=no", eval "radius_cv_decl_needed_$1=yes")])
if eval "test \"`echo '$radius_cv_decl_needed_'$1`\" = yes"; then
  AC_MSG_RESULT(yes)
  radius_tr_decl=NEED_DECLARATION_`echo $1 | tr 'abcdefghijklmnopqrstuvwxyz' 
'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  AC_DEFINE_UNQUOTED($radius_tr_decl)
else
  AC_MSG_RESULT(no)
fi
])dnl

dnl Check multiple functions to see whether each needs a declaration.
dnl RADIUSD_NEED_DECLARATIONS(FUNCTION... [, EXTRA-HEADER-FILES])
AC_DEFUN(RADIUSD_NEED_DECLARATIONS,
[for ac_func in $1
do
RADIUSD_NEED_DECLARATION($ac_func, $2)
done
])

dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
dnl The program must properly implement --version.
AC_DEFUN(AM_MISSING_PROG,
[AC_MSG_CHECKING(for working $2)
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf.  Sigh.
if ($2 --version) < /dev/null > /dev/null 2>&1; then
   $1=$2
   AC_MSG_RESULT(found)
else
   $1="$3/missing $2"
   AC_MSG_RESULT(missing)
fi
AC_SUBST($1)])


dnl Checks to see if this is SUNPro we're building with
dnl Usage:
dnl AC_PROG_CC_SUNPRO
AC_DEFUN(AC_PROG_CC_SUNPRO,
[AC_CACHE_CHECK(whether we are using SUNPro C, ac_cv_prog_suncc,
[dnl The semicolon is to pacify NeXT's syntax-checking cpp.
cat > conftest.c &1; then
  ac_cv_prog_suncc=yes
else
  ac_cv_prog_suncc=no
fi])])

dnl ###
dnl #
dnl #  Look for SNMP in a variety of places.
dnl #
AC_DEFUN(SNMP_CHECKS, [
AC_SUBST(SNMP_LIBS)
AC_SUBST(SNMP_INCLUDE)

AC_MSG_CHECKING([for asn1.h])

dnl #
dnl #  First, see if we can build it WITHOUT using any special includes
dnl #
AC_TRY_COMPILE([
#ifdef HAVE_SYS_TYPES_H
#include 
#endif
#ifdef HAVE_STDINT_H
#include 
#endif
#ifdef HAVE_STDIO_H
#include 
#endif
#ifdef HAVE_NETDB_H
#include 
#endif
#ifdef HAVE_UNISTD_H
#include 
#endif
#include ],
   [ int a = 1;],
   SNMP_INCLUDE="",
   SNMP_INCLUDE=)

dnl #
dnl #  If not, look for it in a number of directories.
dnl #
if test "x$SNMP_INCLUDE" = "x"; then
  old_CFLAGS="$CFLAGS"
  for try in /usr/include/ucd-snmp /usr/local/include/ucd-snmp $snmp_include_dir; do
CFLAGS="$old_CFLAGS -I$try"
AC_TRY_COMPILE([
#ifdef HAVE_SYS_TYPES_H
#include 
#endif
#ifdef HAVE_STDINT_H
#include 
#endif
#ifdef HAVE_STDIO_H
#include 
#endif
#ifdef HAVE_NETDB_H
#include 
#endif
#ifdef HAVE_UNISTD_H
#include 
#endif
#include ],
   [ int a = 1;],
   SNMP_INCLUDE="-I$try",
   SNMP_INCLUDE=)
if test "x$SNMP_INCLUDE" != "x"; then
  break;
fi
  done
  CFLAGS="$old_CFLAGS"
fi

if test "x$SNMP_INCLUDE" = "x"; then
  AC_MSG_RESULT(no)
else
  AC_MSG_RESULT(yes)
  AC_DEFINE(HAVE_ASN1_H)
  
dnl #
dnl #  Check for the rest of the SNMP headers.
dnl #
  old_CFLAGS="$CFLAGS"
  CFLAGS="$CFLAGS $SNMP_INCLUDE"

  AC_MSG_CHECKING(for snmp.h)
AC_TRY_COMPILE([
#ifdef HAVE_SYS_TYPES_H
#include 
#endif
#ifdef HAVE_STDINT_H
#include 
#endif
#ifdef HAVE_STDIO_H
#include 
#endif
#ifdef HAVE_NETDB_H
#include 
#endif
#ifdef HAVE_UNISTD_H
#include 
#endif
#ifdef HAVE_ASN1_H
#include 
#endif
#include ],
   [ int a = 1;],
   [AC_DEFINE(HAVE_SNMP_H) ac_cv_header_snmp_h=yes])
if test "x$ac_cv_header_snmp_h" = "xyes"; then
  AC_MSG_RESULT(yes)
else
  AC_MSG_RESULT(no)
fi

AC_MSG_CHECKING(for snmp_impl.h)
AC_TRY_COMPILE([
#ifdef HAVE_SYS_TYPES_H
#include 
#endif
#ifdef HAVE_STDINT_H
#include 
#endif
#ifdef HAVE_STDIO_H
#include 
#endif
#ifdef HAVE_NETDB_H
#include 
#endif
#ifdef HAVE_UNISTD_H
#include 
#endif

Re: Trouble with 20020715 snapshot

2002-07-16 Thread Ilguiz Latypov


I do have libltdl installed on my system as part of RedHat's libtool RPM 
package.  However, the configure script fails to find the header file 
which exists:

===
$ ./configure --without-snmp \
  --with-system-libtool --disable-ltdl-install \
  --with-ltdl-lib=/usr/lib --with-ltdl-include=/usr/include
[...]
checking for lt_dlinit in -lltdl... yes
checking for ltdl.h... no
configure: warning: libltdl not installed, but installation disabled
[...]

$ rpm -qf /usr/include/ltdl.h 
libtool-1.4.2-5
===

I hacked up the top level configuration files from yesterday's CVS
checkout to reuse the latest auto tools (mine are autoconf 2.53 and
automake 1.6.1).  With those modifications I was able to get rid of link
failure in src/main.  

The bootstrap script allows to remove automatically generated files from
the CVS repository.  However, some constructs in the updated configure.in
are valid only with the newer autoconf.  Perhaps, putting AC_PREREQ(2.53)  
into configure.in could be a good precaution.

Another small problem was due to the sql_fetch_row() prototypes in 

  freeradius/radiusd/src/modules/rlm_sql/drivers/rlm_sql_postgresql/sql_postgresql.h

and

  freeradius/radiusd/src/modules/rlm_sql/drivers/rlm_sql_unixodbc/sql_unixodbc.h

not synchronized with their .c counterparts.  Does the patch included
below fix those prototypes correctly?  Thank you,

Ilguiz

On Tue, 16 Jul 2002, Alan DeKok wrote:

>   If you don't have libltdl onyour system already, then the build
> won't find *any* ltdl.h, and will die.


===
The following file was modified in freeradius/radiusd/src/include:

NameOld version New version Comment
--- --- ---
autoconf.h.in   1.1.1.1 Removed

The accompanying log:

remove automatically generated file

---
The following file was modified in freeradius/radiusd/src/modules/rlm_eap:

NameOld version New version Comment
--- --- ---
Makefile1.1.1.1 Removed

The accompanying log:

remove automatically generated file

---
The following file was modified in 
freeradius/radiusd/src/modules/rlm_eap/types/rlm_eap_tls:

NameOld version New version Comment
--- --- ---
Makefile1.1.1.1 Removed

The accompanying log:

remove automatically generated file

---
The following file was modified in freeradius/radiusd/src/modules:

NameOld version New version Comment
--- --- ---
rules.mak   1.1.1.1 1.2 

The accompanying log:

Specify full path when copying files

The diff of the modified file(s):

--- rules.mak   15 Jul 2002 18:33:26 -  1.1.1.1
+++ rules.mak   16 Jul 2002 17:50:14 -  1.2
@@ -109,11 +109,11 @@
 ###
 static: $(TARGET).a  $(RLM_UTILS)
@[ "x$(RLM_SUBDIRS)" = "x" ] || $(MAKE) $(MFLAGS) WHAT_TO_MAKE=static common
-   @cp $< $(top_builddir)/src/modules/lib
+   @cp $< $(abs_top_srcdir)/src/modules/lib
 
 dynamic: $(TARGET).la $(RLM_UTILS)
@[ "x$(RLM_SUBDIRS)" = "x" ] || $(MAKE) $(MFLAGS) WHAT_TO_MAKE=dynamic common
-   @cp $< $(top_builddir)/src/modules/lib
+   @cp $< $(abs_top_srcdir)/src/modules/lib
 
 ###
 #

---
The following file was modified in 
freeradius/radiusd/src/modules/rlm_eap/types/rlm_eap_md5:

NameOld version New version Comment
--- --- ---
Makefile1.1.1.1 Removed

The accompanying log:

remove automatically generated file

---
The following file was modified in 
freeradius/radiusd/src/modules/rlm_sql/drivers/rlm_sql_unixodbc:

NameOld version New version Comment
--- --- ---
sql_unixodbc.h  1.1.1.1 1.2 

The accompanying log:

Syncronize function prototypes

The diff of the modified file(s):

--- sql_unixodbc.h  15 Jul 2002 18:33:26 -  1.1.1.1
+++ sql_unixodbc.h  16 Jul 2002 17:51:18 -  1.2
@@ -28,7 +28,7 @@
 intsql_store_result(SQLSOCK * sqlsocket, SQL_CONFIG *confi

Re: Trouble with 20020715 snapshot

2002-07-16 Thread Alan DeKok

"Alexandre Strube" <[EMAIL PROTECTED]> wrote:
> I always compile the snapshots with the same configure options, which are
> ./configure  --with-mysql-lib-dir=/usr/lib/mysql \
> --with-mysql-include-dir=/usr/include/mysql \
> --with-mysql-dir=/usr/bin --enable-ltdl-install=no \

  The 'enable-ltdl-install=no' is most likely the problem.

  If you don't have libltdl onyour system already, then the build
won't find *any* ltdl.h, and will die.

  Yeah, looking at your compile output, it's not finding any ltdl.h,
or libltdl.h

  Don't disable ltdl installation.

  Alan DeKok.

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html



Trouble with 20020715 snapshot

2002-07-15 Thread Alexandre Strube

Hello people from the list,

I always compile the snapshots with the same configure options, which are
./configure  --with-mysql-lib-dir=/usr/lib/mysql \
--with-mysql-include-dir=/usr/include/mysql \
--with-mysql-dir=/usr/bin --enable-ltdl-install=no \
--with-experimental-modules

And it was working fine. The last one I did was from July 09.
Today I was doing the same thing on a i686 redhat 6.2 system, and
the following error happened when I typed "make":

creating .libs/radiusdS.c
(cd .libs && gcc -c -fno-builtin -fno-rtti -fno-exceptions "radiusdS.c")
rm -f .libs/radiusdS.c .libs/radiusd.nm .libs/radiusd.nmS .libs/radiusd.nmT
gcc .libs/radiusdS.o -g -O2 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -Wall 
-D_GNU_SOURCE -g -Wshadow -Wpointer-arith -Wcast-qual -
Wcast-align -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes 
-Wmissing-declarations -Wnested-externs -I../include -I/usr/include/ucd-snmp -o 
.libs/radiusd radiusd.o files.o util.o acct.o nas.o log.o valuepair.o version.o 
proxy.o exec.o auth.o timestr.o conffile.o modules.o modcall.o session.o xlat.o 
threads.o smux.o radius_snmp.o client.o request_list.o -Wl,--export-dynamic  
-L/root/porao/freeradius-snapshot-20020715/src/lib -lnsl -lresolv -lpthread -
lpthread /root/porao/freeradius-snapshot-20020715/src/lib/.libs/libradius.so -lsnmp 
-lcrypt -Wl,--rpath -Wl,/usr/local/lib
modules.o: In function `module_list_free':
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:151: undefined reference 
to `lt_dlclose'
modules.o: In function `linkto_module':
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:231: undefined reference 
to `lt_dlopenext'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:233: undefined reference 
to `lt_dlerror'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:254: undefined reference 
to `lt_dlsym'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:256: undefined reference 
to `lt_dlerror'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:260: undefined reference 
to `lt_dlclose'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:269: undefined reference 
to `lt_dlclose'
modules.o: In function `setup_modules':
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:611: undefined reference 
to `lt_dlpreload_default'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:613: undefined reference 
to `lt_dlinit'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:614: undefined reference 
to `lt_dlerror'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:625: undefined reference 
to `lt_dlsetsearchpath'
/root/porao/freeradius-snapshot-20020715/src/main/modules.c:627: undefined reference 
to `lt_dlgetsearchpath'
/root/porao/freeradius-snapshot-20020715/src/lib/.libs/libradius.so: undefined 
reference to `atexit'
collect2: ld returned 1 exit status
gmake[4]: *** [radiusd] Error 1
gmake[4]: Leaving directory `/root/porao/freeradius-snapshot-20020715/src/main'
gmake[3]: *** [common] Error 1
gmake[3]: Leaving directory `/root/porao/freeradius-snapshot-20020715/src'
gmake[2]: *** [all] Error 2
gmake[2]: Leaving directory `/root/porao/freeradius-snapshot-20020715/src'
gmake[1]: *** [common] Error 1
gmake[1]: Leaving directory `/root/porao/freeradius-snapshot-20020715'
make: *** [all] Error 2


Did someting change?



- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html