First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 107428
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Gentoo for Mac OS X <ppc-macos@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Dirk Schoenberger <dirk.schoenberger@freenet.de>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
lib_makefile.patch properly create the needed library patch Dirk Schoenberger 2005-10-02 04:26 0000 356 bytes Details | Diff
tools_clock_rleClock.patch rename the ambigous data type patch Dirk Schoenberger 2005-10-02 04:27 0000 1.04 KB Details | Diff
ebuild.patch ebuild patch patch Fabian Groffen 2005-10-04 11:56 0000 793 bytes Details | Diff
urt-X11R6-dir.patch urt-X11R6-dir.patch patch SpanKY 2005-10-04 16:03 0000 395 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 107428 depends on: Show dependency tree
Bug 107428 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2005-09-27 11:48 0000
While trying to emerge urt-3.1b I ran into the following problem

gcc   -O2 -pipe -I. -I../include     -c -o vaxshort.o vaxshort.c
rm -f librle.a
ar rc librle.a
ar: no archive members specified
usage:  ar -d [-TLsv] archive file ...
        ar -m [-TLsv] archive file ...
        ar -m [-abiTLsv] position archive file ...
        ar -p [-TLsv] archive [file ...]
        ar -q [-cTLsv] archive file ...
        ar -r [-cuTLsv] archive file ...
        ar -r [-abciuTLsv] position archive file ...
        ar -t [-TLsv] archive [file ...]
        ar -x [-ouTLsv] archive [file ...]
make[1]: *** [buildlib] Error 1
make default on tools
make[1]: warning: -jN forced in submake: disabling jobserver mode.
gcc   -O2 -pipe -I. -I../include   applymap.c ../lib/librle.a    -lm -o applymap.new
gcc   -O2 -pipe -I. -I../include   avg4.c ../lib/librle.a    -lm -o avg4.new
powerpc-apple-darwin8-gcc-4.0.0: ../lib/librle.a: No such file or directory
powerpc-apple-darwin8-gcc-4.0.0: ../lib/librle.a: No such file or directory
applymap.c: In function 'main':
applymap.c:69: warning: return type of 'main' is not 'int'
avg4.c: In function 'main':
avg4.c:44: warning: return type of 'main' is not 'int'


Looks like the wrong type of linker calls is used. Is it possible to do e.g a 

gcc   -O2 -pipe -I. -I../include   avg4.c -L../lib -lrle  -lm -o avg4.new

instead of a 

gcc   -O2 -pipe -I. -I../include   avg4.c ../lib/librle.a    -lm -o avg4.new




Reproducible: Always
Steps to Reproduce:
1.
2.
3.




!!! Relying on the shell to locate gcc, this may break
!!! DISTCC, installing gcc-config and setting your current gcc
!!! profile will fix this
Portage 2.0.52-r1 (default-darwin/macos/10.4, gcc-4.0.0, libsystem-7.1-r0, 8.2.0 Power Macintosh)
===============================================================
==
System uname: 8.2.0 Power Macintosh powerpc
macos-20041118
distcc 2.0.1-zeroconf powerpc-apple-darwin7.0 (protocol 1) (default port 3632) [disabled]
dev-lang/python:     [Not Present]
sys-apps/sandbox:    [Not Present]
sys-devel/autoconf:  [Not Present]
sys-devel/automake:  [Not Present]
sys-devel/binutils:  [Not Present]
sys-devel/libtool:   [Not Present]
virtual/os-headers:  7.1
ACCEPT_KEYWORDS="ppc-macos ~ppc-macos"
AUTOCLEAN="yes"
CBUILD="powerpc-apple-darwin"
CFLAGS="-O2 -pipe"
CHOST="powerpc-apple-darwin"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/
qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig collision-protect distlocks sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/Linux/distributions/
gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="ppc emboss gif imagemagick nls png ppc-macos qt sdl slang tiff userland_Darwin kernel_Darwin 
elibc_Darwin"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY

------- Comment #1 From Dirk Schoenberger 2005-10-02 04:25:47 0000 -------
AFter a closer look, the problem seems twofold:

1) librle.a is not created (ar rc librle.a fails, because ar seem to expect a non-empty .o files list)
2) further down, rleClock.c cannot be compiled because a data type symbol is already defined elsewhere

for 1) I  attach a patch against lib/makefile which removes the faulty call
for 2) I attach a patch which renames the problematic type definition and all references from stack_t to 
stack2_t

The makes the package at least compile.

------- Comment #2 From Dirk Schoenberger 2005-10-02 04:26:48 0000 -------
Created an attachment (id=69706) [details]
properly create the needed library

------- Comment #3 From Dirk Schoenberger 2005-10-02 04:27:35 0000 -------
Created an attachment (id=69707) [details]
rename the ambigous data type

------- Comment #4 From SpanKY 2005-10-02 12:48:15 0000 -------
where is stack_t defined ?  in otherwords, post the actual error message please

also, change the ar line to just this and see if it works:
ar rc $(LIBNAME) $(OBJS)

------- Comment #5 From Dirk Schoenberger 2005-10-02 15:06:49 0000 -------
> also, change the ar line to just this and see if it works:
> ar rc $(LIBNAME) $(OBJS)
I uncommented the ar rc line, the ar -q line was lef uncommented.
It built fine.

> where is stack_t defined ?  in otherwords, post the actual error message please

make[2]: warning: jobserver unavailable: using -j1.  Add `+' to parent make rule.
gcc   -O2 -pipe -I. -I../../include     -c -o rleClock.o rleClock.c
rleClock.c: In function 'main':
rleClock.c:188: warning: return type of 'main' is not 'int'
rleClock.c: At top level:
rleClock.c:912: error: conflicting types for 'stack_t'
/usr/include/sys/signal.h:364: error: previous declaration of 'stack_t' was here


------- Comment #6 From SpanKY 2005-10-03 17:36:13 0000 -------
should be fixed in cvs now

------- Comment #7 From Dirk Schoenberger 2005-10-04 11:01:35 0000 -------
> should be fixed in cvs now
Could it please be keyworded ~ppc-macos?

it emerges fine with USE="gif tiff gs". There is some problem with USE="X".
Basically it tries to link with -lX11, but cannot find the proper library, possibly because of some missing 
-L flags.
The message is

 gcc   -O2 -pipe -I. -I../../include     -c -o XGetHClrs.o XGetHClrs.c
gcc   -O2 -pipe -I. -I../../include   getx11.o x11_stuff.o timer.o map_scan.o in_cmap.o XCopyImg.o 
XGetHClrs.o ../../lib/librle.a -lX11 -lXext -lm   -o getx11.new
/usr/bin/ld: can't locate file for: -lX11
collect2: ld returned 1 exit status
make[2]: *** [getx11.out] Error 1
make[1]: *** [subdirs] Error 2
make: *** [default] Error 2

If you add a -L/usr/X11R6/lib in get/getx11/makefile (variable X11LIBS), it at least compile fine.
No idea if this can be added more globally in some configure scripts....

 

------- Comment #8 From Fabian Groffen 2005-10-04 11:03:55 0000 -------
I'm already looking into this... and it's weird.  I don't have a X11.h file,
only X10.h and X.h

------- Comment #9 From SpanKY 2005-10-04 11:46:59 0000 -------
then it sounds like OS X is built off an older version of X, namely X10

------- Comment #10 From Fabian Groffen 2005-10-04 11:56:34 0000 -------
Created an attachment (id=69869) [details]
ebuild patch

Nah, I was too quick.  Linux has exactly the same files, and no X11.h too.

The stuff resides in a different dir for OSX.  I got it compiling now.

Can you agree on the attached patch?

------- Comment #11 From Dirk Schoenberger 2005-10-04 12:09:09 0000 -------
> The stuff resides in a different dir for OSX.  I got it compiling now.

> Can you agree on the attached patch?

Looks good and emerges fine

------- Comment #12 From Fabian Groffen 2005-10-04 12:12:57 0000 -------
... then we wait for a comment by Der Spankmeister.

Have you tried an ebuild that links again the library yet, Dirk?

------- Comment #13 From Dirk Schoenberger 2005-10-04 12:17:39 0000 -------
> Have you tried an ebuild that links again the library yet, Dirk?

I tried to build netpbm, but there seem to be other problems to be solved, yet (#74101).

------- Comment #14 From SpanKY 2005-10-04 16:03:03 0000 -------
Created an attachment (id=69887) [details]
urt-X11R6-dir.patch

try this instead

------- Comment #15 From Fabian Groffen 2005-10-05 07:35:58 0000 -------
patch works fine.

------- Comment #16 From SpanKY 2005-10-05 18:51:05 0000 -------
fixed in cvs then

------- Comment #17 From Fabian Groffen 2005-10-05 22:29:31 0000 -------
not fixed in cvs, because the ebuild is not yet keyworded ppc-macos

------- Comment #18 From SpanKY 2005-10-05 22:30:39 0000 -------
then KEYWORD it :P

------- Comment #19 From Fabian Groffen 2005-10-05 22:34:47 0000 -------
Cannot because I haven't been able to test the library by having another app
compiling/linking against it, hence I cannot guarantee it works.  QA and stuff.

------- Comment #20 From Fabian Groffen 2005-10-05 23:41:18 0000 -------
checked with giflib

as ~ppc-macos in portage

First Last Prev Next    No search results available      Search page      Enter new bug