pg_dump.o(.text+0xf82): undefined reference to `getopt_long'

From: Vicki Brown <vlb(at)cfcl(dot)com>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: pg_dump.o(.text+0xf82): undefined reference to `getopt_long'
Date: 2002-06-01 05:54:55
Message-ID: p05100302b91e10a734a5@[192.168.254.206]
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

uname -a
FreeBSD cfcl.com 4.2-RELEASE FreeBSD 4.2-RELEASE #0: Mon Nov 20 13:02:55 GMT
2000 jkh(at)bento(dot)FreeBSD(dot)org:/usr/src/sys/compile/GENERIC i386

==========================================================
perl -v

This is perl, v5.6.1 built for i386-freebsd

==========================================================
perl -V
Summary of my perl5 (revision 5.0 version 6 subversion 1) configuration:
Platform:
osname=freebsd, osvers=4.2-release, archname=i386-freebsd
uname='freebsd cfcl.com 4.2-release freebsd 4.2-release #0: mon nov 20
13:02:55 gmt 2000 jkh(at)bento(dot)freebsd(dot)org:usrsrcsyscompilegeneric i386 '
config_args='-Umymalloc -Dinstallusrbinperl -des'
hint=recommended, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef
usemultiplicity=undef
useperlio=undef d_sfio=undef uselargefiles=define usesocks=undef
use64bitint=undef use64bitall=undef uselongdouble=undef
Compiler:
cc='cc', ccflags ='-fno-strict-aliasing -I/usr/local/include',
optimize='-O',
cppflags='-fno-strict-aliasing -I/usr/local/include'
ccversion='', gccversion='2.95.2 19991024 (release)', gccosandvers=''
intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=12
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t',
lseeksize=8
alignbytes=4, usemymalloc=n, prototype=define
Linker and Libraries:
ld='cc', ldflags ='-Wl,-E -L/usr/local/lib'
libpth=/usr/lib /usr/local/lib
libs=-lbind -lm -lc -lcrypt -lutil
perllibs=-lbind -lm -lc -lcrypt -lutil
libc=, so=so, useshrplib=false, libperl=libperl.a
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' '
cccdlflags='-DPIC -fpic', lddlflags='-shared -L/usr/local/lib'

Characteristics of this binary (from libperl):
Compile-time options: USE_LARGE_FILES
Built under freebsd
Compiled at May 14 2002 00:06:28
@INC:
/usr/local/lib/perl5/5.6.1/i386-freebsd
/usr/local/lib/perl5/5.6.1
/usr/local/lib/perl5/site_perl/5.6.1/i386-freebsd
/usr/local/lib/perl5/site_perl/5.6.1
/usr/local/lib/perl5/site_perl/5.005/i386-freebsd
/usr/local/lib/perl5/site_perl/5.005
/usr/local/lib/perl5/site_perl

==========================================================
the version of PostgreSQL - 7.2.1

==========================================================
and the version of pgsql_perl5
This is version 1.8.0 of pgsql_perl5 (previously called pg95perl5).

as included in the PostgreSQL - 7.2.1 distribution.

==========================================================
What I did:

I ran
./configure --with-perl
gmake

I got to a point that complained about
getopt.h: file not found

I located
/usr/src/contrib/binutils/include/getopt.h
and copied it to /usr/include

I ran gmake again

I eventually got this error:

gmake[3]: Entering directory
`/usr/ports/databases/postgresql7/work/postgresql-7.2.1/src/bin/pg_dump'

...
cc -pipe -O2 -Wall -Wmissing-prototypes -Wmissing-declarations pg_dump.o
common.o pg_backup_archiver.o pg_backup_db.o pg_backup_custom.o
pg_backup_files.o pg_backup_null.o pg_backup_tar.o
-L../../../src/interfaces/libpq -lpq -R/usr/local/pgsql/lib -lz -lbind
-lcrypt -lcompat -lm -lutil -lreadline -o pg_dump
pg_dump.o: In function `main':
pg_dump.o(.text+0xf82): undefined reference to `getopt_long'
gmake[3]: *** [pg_dump] Error 1
gmake[3]: Leaving directory

getopt_long is defined in the getopt.h I copied.

Suggestions?
--
- Vicki

Vicki Brown ZZZ Journeyman Sourceror:
P.O. Box 1269 zz |\ _,,,---,,_ Scripts & Philtres
San Bruno, CA zz /,`.-'`' -. ;-;;,_ Perl, Unix, MacOS
94066 USA |,4- ) )-,_. ,\ ( `'-'
mailto:vlb(at)cfcl(dot)com '---''(_/--' `-'\_) http://www.cfcl.com/~vlb

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Bistey Csaba 2002-06-03 13:18:56 lo_import problem under Windows+BCB5
Previous Message Tom Lane 2002-05-30 23:40:07 Re: Direct XML interfaces to optimizer and even executor?