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

20050316: building udunits on 64-bit, Suse 9.2, and PGI linux86_64 compilers



Neil,

>Date: 16 Mar 2005 18:15:24 -0600
>From: "Neil R. Smith" <address@hidden>
>Organization: Texas A&M University
>To: Steve Emmerson <address@hidden>
>Subject: Re: 20050316: building udunits on 64-bit, Suse 9.2, and PGI 
>linux86_64 compilers

The above message contained the following:

> OK. Did that. make fails in the perl area.
> config.log and make.out attached
[snip]

> making `dynamic' in directory /usr/local/src/udunits-1.12.4/src/perl
> 
> make[1]: Entering directory `/usr/local/src/udunits-1.12.4/src/perl'
> /usr/bin/perl /usr/lib/perl5/5.8.5/ExtUtils/xsubpp  -typemap /usr/lib/perl5=
> /5.8.5/ExtUtils/typemap -typemap typemap  UDUNITS.xs > UDUNITS.xsc && mv UD=
> UNITS.xsc UDUNITS.c
> Please specify prototyping behavior for UDUNITS.xs (see perlxs manual)
> cc -c  -I../lib -I../port/misc -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PI=
> DS -fno-strict-aliasing -pipe -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=3D64 =
> -O2 -fmessage-length=3D0 -Wall -Wall -pipe   -DVERSION=3D\"1.12.4\" -DXS_VE=
> RSION=3D\"1.12.4\" -fPIC "-I/usr/lib/perl5/5.8.5/x86_64-linux-thread-multi/=
> CORE"  -DpgiFortran UDUNITS.c
> UDUNITS.xs: In function `constant':
> UDUNITS.xs:160: warning: label `not_there' defined but not used
> UDUNITS.c: At top level:
> UDUNITS.xs:14: warning: `not_here' defined but not used
> Running Mkbootstrap for UDUNITS ()
> chmod 644 UDUNITS.bs
> rm -f blib/arch/auto/UDUNITS/UDUNITS.so
> LD_RUN_PATH=3D"" cc  -shared -L/usr/local/lib64 UDUNITS.o  -o blib/arch/aut=
> o/UDUNITS/UDUNITS.so   -L/usr/local/src/udunits-1.12.4/src/perl/../lib -lud=
> units -lm  =20
> /usr/lib64/gcc-lib/x86_64-suse-linux/3.3.4/../../../../x86_64-suse-linux/bi=
> n/ld: /usr/local/src/udunits-1.12.4/src/perl/../lib/libudunits.a(utlib.o): =
> relocation R_X86_64_32 against `a local symbol' can not be used when making=
>  a shared object; recompile with -fPIC
> /usr/local/src/udunits-1.12.4/src/perl/../lib/libudunits.a: could not read =
> symbols: Bad value
> collect2: ld returned 1 exit status
> make[1]: *** [blib/arch/auto/UDUNITS/UDUNITS.so] Error 1
> make[1]: Leaving directory `/usr/local/src/udunits-1.12.4/src/perl'
> make: *** [perl/dynamic] Error 1

Looks like the compilation of the UDUNITS library needs the "-fPIC"
option.

Do a "make distclean" and retry with the following settings:

    CFLAGS='-O -fno-builtin -fPIC'      # additional option
    CPPFLAGS=-DpgiFortran               # same as before

Regards,
Steve Emmerson