Article View: comp.os.os2.programmer
Article #794Help needed on putting a *.o file in a library *.a file
From: Shuqian Ying
Date: Sun, 06 Sep 1992 22:22
Date: Sun, 06 Sep 1992 22:22
25 lines
1408 bytes
1408 bytes
I installed the gnu-c2.1 (emx) few weeks ago under MSDOS. It works great
in doing large (relatively, I must say) numerical computation with a speed
comparable to vax workstations. However I have a problem puting some of the
*.o files compiled from *.s files using 'as'. The following is what I did
(for example, I shall compile pow.s and put it into libc.a)
as -o pow.o pow.s
ar dv libc.a __.SYMDEF
ar rv libc.a pow.o
ar sv libc.a
Then, I used the following command to compile myprogram.c, which calls
pow(x,y)
gcc -o -O2 myprogram.exe myprogram.c
The compiler would complain that all of the variables defined in pow.s
are undefined. (For your reference they are cw1,cw2,int_exponent,x,y.)
Could any one give me some suggestions what should I do to correct that?
I appreciate you help.
P.S. I am sorry that I post a question not related to OS2, but it seems
that this is THE group where people really discuss gnu-c(emx).
Technical Details
Message-ID:
<ying.715818155@dirac>Path:
arc1-ca.pugleaf.net!sparky!uunet!ogicse!news.u.washington.edu!dirac!yingShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!ogicse!news.u.washington.edu!dirac!ying From: ying@dirac.phys.washington.edu (Shuqian Ying) Newsgroups: comp.os.os2.programmer Subject: Help needed on putting a *.o file in a library *.a file Keywords: DOS, EMX, GCC, AS Message-ID: <ying.715818155@dirac> Date: 6 Sep 92 22:22:35 GMT Article-I.D.: dirac.ying.715818155 Sender: news@u.washington.edu (USENET News System) Organization: University of Washington Lines: 25