- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi.
I compiled application with 10.1.025, but I don't known how to exclude library or library's link what I don't need to compile into the application. Which flag I can add?
For example, I want to exclude the /lib64/libpthread.so.0 library, How to do?
Please help me. Thanks.
King Regards.
wowfans.
I compiled application with 10.1.025, but I don't known how to exclude library or library's link what I don't need to compile into the application. Which flag I can add?
For example, I want to exclude the /lib64/libpthread.so.0 library, How to do?
Please help me. Thanks.
King Regards.
wowfans.
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You could have the compiler pass any arguments you wish into the linker script by -Wl, in case that is part of your question. Most of your options would be described in the binutils manual (easily found by your search engine).
The default library search path is inherited from your gcc specs file; obviously, we can't support tinkering with it.
In the case of libpthread, you could avoid searching it simply by not setting options which require it, or renaming it if your purpose is to use one which comes later on your search path.
The default library search path is inherited from your gcc specs file; obviously, we can't support tinkering with it.
In the case of libpthread, you could avoid searching it simply by not setting options which require it, or renaming it if your purpose is to use one which comes later on your search path.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - wowfans
For example, I want to exclude the /lib64/libpthread.so.0 library, How to do?
May I use --exclude-libs=lpthread? The version is ICC 10.1.025_intel64.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That would be -Wl,'--exclude-libs ...' if passed through icc. As the documentation says this applies to .a libraries, you would have to find out if .so libraries are affected. If you are searching lpthread, it's because you have included it yourself, or specified an option which includes it. For icc, the options which imply -lpthread are -parallel and -openmp. For icc 10.1, either of those options adds -lguide -lpthread in the link script, as you are asking icc to generate OpenMP code. icc 10.1 also offers the gnu compatible replacement for -lguide (-liomp5). All of the libguide and libiomp libraries require libpthread, possibly even the "sequential" stub libraries.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page