Port-amiga archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: freeradius fails to build



DataZap wrote:

> threads.c:(.text+0x25a): undefined reference to `pthread_create'
> threads.c:(.text+0x26c): undefined reference to `pthread_attr_destroy'
> .libs/threads.o: In function `thread_pool_clean':

The software obviously needs access to those thread functions and the
following command line does not contain a reference to the thread
library:

> [wrapper.sh] note: The real command line, after the pkgsrc wrapper, was:
> /usr/pkgsrc/net/freeradius/work/.gcc/bin/gcc .libs/radiusdS.o
> -Wl,-R/usr/local/lib -Wl,-R/usr/local/lib/mysql -o .libs/radiusd
> .libs/acct.o .libs/auth.o .libs/client.o
>  .libs/conffile.o .libs/exec.o .libs/files.o .libs/log.o
> .libs/mainconfig.o .libs/modules.o .libs/modcall.o .libs/nas.o
> .libs/proxy.o .libs/radiusd.o .libs/radius_snmp
> .o .libs/request_list.o .libs/session.o .libs/smux.o .libs/threads.o
> .libs/util.o .libs/valuepair.o .libs/version.o .libs/timestr.o
> .libs/xlat.o -Wl,--export-dynamic -
> L/usr/pkgsrc/net/freeradius/work/.buildlink/lib
> -L/usr/pkgsrc/net/freeradius/work/.buildlink/lib/mysql
> ../lib/.libs/libradius.so -Wl,--rpath,/usr/local/lib -I/usr/pkgs
> rc/net/freeradius/work/.buildlink/include -lresolv -lcrypt -lltdl

This is strange because the pkgsrc Makefile contains the line
  .include "../../mk/pthread.buildlink3.mk"

For me, the line in work/.work.log looks like this

<.> /scr/pkgsrc-2007Q1/net/freeradius/work.i386/.gcc/bin/gcc
  .libs/radiusdS.o -Wl,-R/usr/pkg/lib -o .libs/radiusd .libs/acct.o .libs/auth.o
  .libs/client.o .libs/conffile.o .libs/exec.o .libs/files.o .libs/log.o
  .libs/mainconfig.o .libs/modules.o .libs/modcall.o .libs/nas.o .libs/proxy.o
  .libs/radiusd.o .libs/radius_snmp.o .libs/request_list.o .libs/session.o
  .libs/smux.o .libs/threads.o .libs /util.o .libs/valuepair.o
  .libs/version.o .libs/timestr.o .libs/xlat.o -pthread
  -Wl,--export-dynamic
  -L/scr/pkgsrc-2007Q1/net/freeradius/work.i386/.buildlink/lib
  ../lib/.libs/libradius.so -Wl,--rpath,/usr/pkg/lib
  -I/scr/pkgsrc-2007Q1/net/freeradius/work.i386/.buildlink/include
  -lresolv -lcrypt -lltdl

Note the additional "-pthread" after .libs/xlat.o.

Please show the output of
  "make show-var VARNAME=PTHREAD_TYPE"
and
  "head -15 work/freeradius-*/config.log"

You probably set "PKG_OPTIONS.freeradius=mysql", did you change anything
in the pkgsrc Makefile?

Do you use a pkgsrc branch or the HEAD of pkgsrc? Which version of
NetBSD?

ciao
     Klaus



Home | Main Index | Thread Index | Old Index