site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=googlemail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=WE765Chu4UaEn6sYsSmLIGwrVhQtseM9TJfHD4KwVt2okoF4eSqZ3cxrPO50guJjpW6EDodHoJW2+6fiTeCIMiFBsuCFaCZU+1EeTbvvIVKwm1XE1MmGWLKfzZmGRkdiJlK12xd5M5jZhnTd/uCVv1GG2JHh5k4mdWfPjyDGWp4= Domainkey-signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=BfDzl05DWvO5bzB29W/BWjbYuhSrM4ss7KBU4hOe/e8PYcLkhU2mSkbw8W6dgOtxMxL71qqJa3senVZcQbLhX7RBF7/9AmXTLVW0cJHf6vlxBUB/r+f0Q+E1O+v4YL3wAmDCQOLF4A2/ha+xOBOQKI1u79uZsWpGQXFvkekg2hI= Hello. I'm trying to produce working fat binary shared libraries from the command line. I'm encountering linker errors. Platform is PPC with a clean install of 10.4.9 (8.9.0) and up-to-date developer tools. I have the following files: /* t.h */ #ifndef T_H #define T_H void t1(void); void t2(void); void t3(void); #endif /* t1.c */ #include <stdio.h> #include "t.h" void t1(void) { printf("t1\n"); } /* t2.c */ #include <stdio.h> #include "t.h" void t2(void) { printf("t2\n"); } /* t3.c */ #include <stdio.h> #include "t.h" void t3(void) { printf("t3\n"); } Makefile: t.dylib: t.h t1.o t2.o t3.o libtool -dynamic -o t.dylib t1.o t2.o t3.o -lSystemStubs -lc t1.o: t1.c t.h cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t1.o t1.c t2.o: t2.c t.h cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t2.o t2.c t3.o: t3.c t.h cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t3.o t3.c clean: rm -f t.dylib t1.o t2.o t3.o I'm getting this error: $ make cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t1.o t1.c cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t2.o t2.c cc -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -c -dynamic -o t3.o t3.c libtool -dynamic -o t.dylib t1.o t2.o t3.o -lSystemStubs -lc ld: for architecture i386 ld: Undefined symbols: _puts libtool: internal link edit command failed make: *** [t.dylib] Error 1 What is the correct way to produce shared libraries from the command line in this manner? My method obviously isn't right... thanks, MC _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... This email sent to site_archiver@lists.apple.com