incorporer des librairies avec la commande gcc

B

Bigorre.Edouardd

bonjour,

j'ai une erreur de compilage qui me revient souvent qui est :
"undefined reference ", il s'agit d'un probleme de librairie. Je
voulais savoir comment on faisait pour incorporer des librairies avec
la commande gcc ?
par avance merci
 
J

Joona I Palaste

(e-mail address removed) scribbled the following:
j'ai une erreur de compilage qui me revient souvent qui est :
"undefined reference ", il s'agit d'un probleme de librairie. Je
voulais savoir comment on faisait pour incorporer des librairies avec
la commande gcc ?
par avance merci

Pour vous aider se trouve le option "-l" (un lettre ell, pas un nombre
un), apres cette se trouve le nom de librairie. Pour example: si
le librairie s'appelle "foobar", peuvez vous ecriver "-lfoobar" sur
la commande gcc.

--
/-- Joona Palaste ([email protected]) ---------------------------\
| Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
| http://www.helsinki.fi/~palaste W++ B OP+ |
\----------------------------------------- Finland rules! ------------/
"Bad things only happen to scoundrels."
- Moominmamma
 
D

Derk Gwen

(e-mail address removed) wrote:
# bonjour,
#
# j'ai une erreur de compilage qui me revient souvent qui est :
# "undefined reference ", il s'agit d'un probleme de librairie. Je
# voulais savoir comment on faisait pour incorporer des librairies avec
# la commande gcc ?
# par avance merci

Most simply, include the path to the library

gcc -o executable abc.o def.o /usr/local/lib/libghi.so genesis/abacab/jkl.a ...
 
I

Irrwahn Grausewitz

bonjour,

j'ai une erreur de compilage qui me revient souvent qui est :
"undefined reference ", il s'agit d'un probleme de librairie. Je
voulais savoir comment on faisait pour incorporer des librairies avec
la commande gcc ?
par avance merci

1. Sorry, we speak English here, though c.l.c is a rather international
newsgroup.

2. From what I can read out of your post you have problems linking
libraries with gcc. This is off-topic in c.l.c - please read in your
compiler manual about the -l and -L options, or refer to a more
appropriate newsgroup.

Regards

Irrwahn
 
M

Mac

1. Sorry, we speak English here, though c.l.c is a rather international
newsgroup.

Is this official? There seem to be enough regulars here passable (or even
fluent) in French to support French questions.

In any event, as a matter of fact, French questions seem to get answered
most of the time.

Of course, the particular question above is technically off-topic anyway,
since it is about gcc, not c.

Mac
--
 
A

Arthur J. O'Dwyer

Is this official? There seem to be enough regulars here passable (or even
fluent) in French to support French questions.

In any event, as a matter of fact, French questions seem to get answered
most of the time.

Yes; as I understand and approve of it, comp.lang.c is an
English-language newsgroup by default; French questions go to
fr.comp.lang.c or whatever the equivalent is (kind of like
most WWW sites not in a specific top-level national domain
like .fr or .ru are English-language by default). And Polish
questions go to pl.foo, and so on. However, as you say, we
have enough people reasonably fluent in other languages to
support the occasional non-English question. I've attempted
to answer Spanish OPs on occasion, for instance.

But of course, you're not going to get as good answers to
questions that not everyone can understand. If I can't
read your post, I can't very well comment on it (except to
say, "hey, post in English next time!" ;-) And too many
non-English posts would turn the newsgroup into a veritable
Babel, with everyone having to filter out all the posts in
languages he didn't know. It'd be a mess. That's why the
language-specific groups exist.

-Arthur
 
R

Richard Heathfield

Mac said:
Is this official?

No, but that doesn't stop it being true. In fact, we use English here
/because/ clc is an international group. English is the lingua franca(!) of
the world, de facto. We insist on English for the same reason that Moroccan
gunrunners insist on US dollars.
There seem to be enough regulars here passable (or even
fluent) in French to support French questions.

Le problem, il est ceci, que l'expertise du subscribeurs du newsgroup-ci,
c'est dans la langue C. Notre French, elle est not so bon. Le bottom ligne
est ce fewer experts sont going to etuder et peut-etre reponder a votre
question s'ils ne pouvent pas read it ou comprener it. As vous can see, les
answers from those who /do/ reponder are likely etre lacking in either C
expertise ou, possiblement, expertise du francais. Il est une recipe pour
un complete pig's breakfast of a newsgroup.
In any event, as a matter of fact, French questions seem to get answered
most of the time.

Why not use fr.comp.lang.c? That's what it's there for.
 
M

Mac

English is the lingua franca(!) of
the world

You have a keen eye for irony... ;-)
Le problem, il est ceci, que l'expertise du subscribeurs du newsgroup-ci,
c'est dans la langue C. Notre French, elle est not so bon. Le bottom ligne
est ce fewer experts sont going to etuder et peut-etre reponder a votre
question s'ils ne pouvent pas read it ou comprener it. As vous can see, les
answers from those who /do/ reponder are likely etre lacking in either C
expertise ou, possiblement, expertise du francais. Il est une recipe pour
un complete pig's breakfast of a newsgroup.

Hmm. Is "pig's breakfast" a literal translation of a French colloquialism?
Why not use fr.comp.lang.c? That's what it's there for.

Oh, I'm not a francophone. I can usually understand the questions (and I
was able to understand your franglish) but I couldn't answer as readily as
some others here. I just seem to recall several questions being asked in
French without anyone complaining.

Thanks for clarifying.

Mac
--
 
M

Mac

Yes; as I understand and approve of it, comp.lang.c is an
English-language newsgroup by default; French questions go to
fr.comp.lang.c or whatever the equivalent is (kind of like
most WWW sites not in a specific top-level national domain
like .fr or .ru are English-language by default). And Polish
questions go to pl.foo, and so on. However, as you say, we
have enough people reasonably fluent in other languages to
support the occasional non-English question. I've attempted
to answer Spanish OPs on occasion, for instance.

But of course, you're not going to get as good answers to
questions that not everyone can understand. If I can't
read your post, I can't very well comment on it (except to
say, "hey, post in English next time!" ;-) And too many
^^^^^^^^^^^^
non-English posts would turn the newsgroup into a veritable
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Babel, with everyone having to filter out all the posts in
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
languages he didn't know. It'd be a mess. That's why the ^^^^^^^^^^^^^^^^^^^^^^^^^
language-specific groups exist.

True enough. Thanks for your response.

Mac
--
 
C

Chris Dollin

Dan said:
What do English pigs get for breakfast?

Whatever the farmer wants to give them. It's compatible with "dog's
dinner". For those in the audience listening in black-and-white,
the translation is "a bit of a mess", which is in turn English for
"a complete and unrecoverable mess", at least for those of us who
still remember understatement.
 
A

Andreas Kahari

Dan Pop wrote: [cut]
What do English pigs get for breakfast?

The usually get English breakfast...
Whatever the farmer wants to give them. It's compatible with "dog's
dinner". For those in the audience listening in black-and-white,
the translation is "a bit of a mess", which is in turn English for
"a complete and unrecoverable mess", at least for those of us who
still remember understatement.

And a mess is, of course, a place to eat in, or possibly
something to eat.
 
A

Arthur J. O'Dwyer

Whatever the farmer wants to give them. It's compatible with "dog's
dinner". For those in the audience listening in black-and-white,
the translation is "a bit of a mess", which is in turn English for
"a complete and unrecoverable mess", at least for those of us who
still remember understatement.

And for those of us who don't, a rough translation
into MTV vernacular might be "an X-treme Mess! (tm)"

-Arthur
 
J

Joona I Palaste

And for those of us who don't, a rough translation
into MTV vernacular might be "an X-treme Mess! (tm)"

D00d. Sup. Word. And other "hip" lingo.

--
/-- Joona Palaste ([email protected]) ---------------------------\
| Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
| http://www.helsinki.fi/~palaste W++ B OP+ |
\----------------------------------------- Finland rules! ------------/
"No, Maggie, not Aztec, Olmec! Ol-mec!"
- Lisa Simpson
 
L

LibraryUser

Chris said:
Whatever the farmer wants to give them. It's compatible with "dog's
dinner". For those in the audience listening in black-and-white,
the translation is "a bit of a mess", which is in turn English for
"a complete and unrecoverable mess", at least for those of us who
still remember understatement.

It sounds like a large steaming pile of equine excretions.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,048
Latest member
verona

Latest Threads

Top