473,408 Members | 1,734 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

g++ can't locate dylib to link at

Hello,
I'm using g++ over eclipse in a mac os x. I'm new to all these
technologies.
I created a dylib, and to test it I made another project that links to
it, but the compiler tells me that it can't locate it.
In my last build I used absolute path to be sure of the location, but
it still delivers an error.
The output is:

**** Build of configuration Debug for project gnawa_tester ****

make -k all
Building target: gnawa_tester
Invoking: MacOS X C++ Linker
g++ `/Volumes/Quark/c++projects/wxconf-debug` -L/Volumes/Quark/c+
+projects/gnawax/gnawa_proj/build/Debug -o "gnawa_tester" ./
SynthetGUI.o ./main.o -llibgnawa_proj
/usr/bin/ld: can't locate file for: -llibgnawa_proj
collect2: ld returned 1 exit status
make: *** [gnawa_tester] Error 1
make: Target `all' not remade because of errors.
Build complete for project gnawa_tester

Any help? I'm stuck here for one day and a half..
Thank you in advance.

Mar 10 '07 #1
3 4921
bowser wrote:
Hello,
I'm using g++ over eclipse in a mac os x. I'm new to all these
technologies.
I created a dylib, and to test it I made another project that links to
it, but the compiler tells me that it can't locate it.
In my last build I used absolute path to be sure of the location, but
it still delivers an error.
The output is:

**** Build of configuration Debug for project gnawa_tester ****

make -k all
Building target: gnawa_tester
Invoking: MacOS X C++ Linker
g++ `/Volumes/Quark/c++projects/wxconf-debug` -L/Volumes/Quark/c+
+projects/gnawax/gnawa_proj/build/Debug -o "gnawa_tester" ./
SynthetGUI.o ./main.o -llibgnawa_proj
/usr/bin/ld: can't locate file for: -llibgnawa_proj
collect2: ld returned 1 exit status
make: *** [gnawa_tester] Error 1
make: Target `all' not remade because of errors.
Build complete for project gnawa_tester

Any help? I'm stuck here for one day and a half..
Thank you in advance.
This is a group for C++, not a group about how to use your compiler or
build environment. You really should ask on a Mac programing group, and
eclipse group, even a g++ group but not here.

Now I'm not an expert on any of the things you are doing but if I were
you I'd try -lgnawa_proj not -llibgnawa_proj, it will only take you two
minutes to try, who knows it might even work. If it doesn't try a Mac
programming group. I think they would be best placed to help you.

john
Mar 10 '07 #2
ok, thanks and sorry for the inconvenience.
By the way, I've already tried the way you suggested, and also tried
with and without the extension.

Mar 10 '07 #3
Well, no, you were right!
Even if the library build name starts with "lib", I have to remove
that prefix in order to link it.
Before I tried to build it without that prefix.
Thank you!

Mar 10 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: OpenMacNews | last post by:
hi all, i've successfully built Python-2.4.1 from src on OSX 10.3.8 as a framework install with: ./configure \ --enable-framework \ --with-threads \ --with-cxx=g++ \ --enable-ipv6 \
0
by: packrat | last post by:
I am attempting to build a Bugzilla server on OS X. All of this is new to me, working with the Perl, MySQL, and Bugzilla, so I have been banging my head often. Software error: When I run the...
0
by: Anthony | last post by:
I am trying to make a simple page display a rss news feed.. I don't want the web server to connect to remote site because it doesn't work. I want the client to do it because my web server is behind...
1
by: Anthony | last post by:
Sorry about the repost but i didn't get any responses.... I am trying to make a simple page display a rss news feed.. I don't want the web server to connect to remote site because it doesn't...
3
by: robspychala | last post by:
Hi Is there something similar to python's windll for calling DLLs on win32 but meant for calling dylib's on OS X? thanks, r.s.
3
by: ET | last post by:
I don't know whats the problem, but after I added functions to first verify, then relink linked tables if not found, now I can't convert that database to MDE format. I can split the database, but...
6
by: Osama Rajab | last post by:
Hi Guys, When I skim fast into my old code or others code, I forget what the type of a certain variable was or what its initialization value was. We use the Hungarian notation and it helps to...
3
by: Jason | last post by:
Hi, I built a vb.Net application that creates ICS calendar files dynamically and then sends them to the client browser as a downloadable file. Works perfectly except in the following situation....
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.