Solved

problem linking with m68k-palmos-gcc

Posted on 2004-10-15
2
531 Views
Last Modified: 2013-12-27
Hello. I´m working on W2000 using cygwin.dll to compile with m68k-palmos-gcc. I had a problem because i had to use the ScanMgr library and that library provided with CodeWarrior is a .lib library and i didn't can link it.
Someone here (i forget his name) give me the libScanMgr.a library but i tried to compile with it using options -L and -l to set the complete path and the library file and every command that i try tells me:

/prc-tools/H-i586-cygwin32/m68k-palmos/bin/ld: cannot open -llibScanMgr.a: No such file or directory

or give me the complete list of undefined references like

C:\DOCUME~1\Martin\CONFIG~1\Temp/ccyt5xaY.o(.text+0x2ae):pscanner.cpp: undefined reference to `ScanIsPalmSymbolUnit(void)'

Can anybody tell me the exactly command that can link libScanMgr.a. ?
Remember that i tried the typical -L and -l options in conjunction.
Thanks
0
Comment
Question by:martin11_ar
2 Comments
 
LVL 6

Expert Comment

by:vadim_ti
ID: 12330288
m68k-palmos-gcc -o 1.o 2.o ... n.o Symbol/lib/libScanMgr.a
0
 
LVL 3

Accepted Solution

by:
olan75 earned 125 total points
ID: 12466702
Remember that gcc changes the name that you give on the command line:
for example -lFoo will cause gcc to link with libFoo.a

So assuming your lib is in the same directory as your object files, the
link line should have : -lScanMgr and NOT -llibScanMgr

However, you do not need the -l option.
You can link with a library by adding it directly to the command line as if it were another .o file

For instance:

m68k-palmos-gcc foo.o bar.o libScanMgr.a

would work (add other options to your liking). gcc looks at the extension and does the right thing.

This is better because that way you can specify
exactly THE lib you want, instead of relying on a path (a path is dangerous because you could
have several libs with the same name along the path, so you have to worry about
which one is first in the path...) .

If none of the above works then post your link line and explain your directory structure.

HTH
olan75

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

With Windows Embedded Handheld, called Windows Mobile, Microsoft re-designed the user interface. The Start Icon moved down to the bottom, inside the menu bar area.   If you need to hide the Start Icon and/or the SIP (soft input panel, softwar…
Preface: This article is part of a series focused on cross platform mobile app development (specifically Android and iOS) using the Alloy framework and Titanium Studio made by Appcelerator (https://www.appcelerator.com/). This article presumes a wor…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now