Note that there are some explanatory texts on larger screens.

plurals
  1. POlinking and executable by hand without alternatives
    primarykey
    data
    text
    <p>I use <code>gcc</code> more than any other compiler, so I will shape my example with this compiler suite, but i have experienced this problem with almost all the suite that i have tried like <code>gcc</code>, <code>mingw</code>, <code>clang</code> and <code>msvc</code>.</p> <p><code>gcc</code> offers this flags:</p> <ul> <li><code>-l</code> you write the name <code>foo</code>, gcc will find a corrisponding library named <code>libfoo</code></li> <li><code>-L</code> you append the path where the libs lives and gcc tries to match the required libraries to the ones that it finds in that path</li> <li><code>-rpath</code> basically a pool of different path for the same lib so the executable is "smart" enough to look for alternatives if he needs one.</li> </ul> <p>the problem is big for me, no one of this solves my problem and each one of this flags suffer the same problem: ambiguity.</p> <p>if I just want to link a library that i know there is no way to do this without including a dose of ambiguity in the best case scenario, what i want is:</p> <ul> <li>linking 1 specific library only, and only the 1 that I specify with a precise name and path</li> <li>avoid auto-completion mechanism like the one on the name given to <code>-l</code> because my libs are named <code>foo.so</code> not <code>libfoo.so</code></li> <li>relative path for the linked libs</li> <li>only consider the explicitly given set of libraries, no other automation of any kind should be involved, no pool of libs, no search-paths, no nothing else, I prefer list of errors instead of an executable linked to a random library</li> </ul> <p>I often deal with different libs in different releases, they often share the same name for historical and compatibility reasons, it's a nightmare compiling and linking with gcc because I never got the one that I want linked to my executable. </p> <p>Thanks.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload