Opened 21 years ago

Closed 21 years ago

Last modified 19 years ago

#420 closed defect (fixed)

ld: Undefined symbols: error on attempts to build packages

Reported by: pdb2@… Owned by: eric@…
Priority: Normal Milestone:
Component: base Version: 1.0
Keywords: Cc:
Port:

Description

I get these errors when I try to compile gd or libpng.

ranlib: file: libgd.a(gdcache.o) has no symbols cc -I. -I/usr/include/freetype2 -I/usr/include/X11 -I/usr/X11R6/include/X11 -I/opt/local/ include -O -DHAVE_LIBPNG -DHAVE_LIBJPEG -fno-common -no-cpp-precomp -c -o pngtogd.o pngtogd.c cc -I. -I/usr/include/freetype2 -I/usr/include/X11 -I/usr/X11R6/include/X11 -I/opt/local/ include pngtogd.o -o pngtogd -L. -L/opt/local/lib -L/usr/local/lib -L/usr/lib/X11 -L/usr/ X11R6/lib -lgd -lpng -lz -ljpeg ld: warning -L: directory name (/usr/lib/X11) does not exist ld: warning -L: directory name (/usr/X11R6/lib) does not exist ld: warning multiple definitions of symbol _main pngtogd.o definition of _main in section (TEXT,text) /usr/local/lib/libgd.dylib(libgd.2.0.0.dylib-master.o) definition of _main ld: Undefined symbols: _gdImageCreateFromPng gnumake: * [pngtogd] Error 1

Darwin D-128-95-132-49.dhcp4.washington.edu 6.4 Darwin Kernel Version 6.4: Wed Jan 29 18:50:42 PST 2003; root:xnu/xnu-344.26.obj~1/RELEASE_PPC Power Macintosh powerpc

bash-2.05a# cc -v Reading specs from /usr/libexec/gcc/darwin/ppc/3.1/specs Thread model: posix Apple Computer, Inc. GCC version 1175, based on gcc version 3.1 20020420 (prerelease)

Change History (4)

comment:1 Changed 21 years ago by fkr@…

Owner: changed from kevin@… to eric@…

I believe this is caused by lacking X-libraries. (this is just an assumption based upon the compile error down below). libpng should be the one needed to depend on X. I'll reassign the bug to eric@ since he is the maintainer of these ports.

comment:2 Changed 21 years ago by pdb2@…

curious, since I have X installed and I would assume the libraries would be there. Is there any further information I can provide that will help unravel this?

On further review, this may resolved: I just tried installing gd again and all went reasonably well (mixed results are below).

bash-2.05a# port install ---> Installing gd Error: Target com.apple.install returned: shell command "ln -s /opt/local/lib/libgd.1.8.dylib / Users/paul/src/darwinports/dports/graphics/gd/work/destrootopt/local/lib/libgd.dylib" returned error 1 Command output: ln: /Users/paul/src/darwinports/dports/graphics/gd/work/destrootopt/ local/lib/libgd.dylib: File exists

bash-2.05a# port clean ---> Cleaning gd bash-2.05a# port install ---> Fetching gd ---> Verifying checksum for gd ---> Extracting gd ---> Configuring gd ---> Building gd with target all ---> Installing gd

comment:3 Changed 21 years ago by landonf@…

Resolution: fixed
Status: newclosed

If this is now working for you, I'd like to close it as fixed.

comment:4 Changed 21 years ago by pdb2@…

Yes, this can be closed.

Note: See TracTickets for help on using tickets.