Gentoo Archives: gentoo-dev

From: Didi <ribalba@×××××.com>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] g++ problem
Date: Mon, 28 May 2007 15:25:50
Message-Id: 20a764e60705280823r108e6215n59f8ab3194aa7ea@mail.gmail.com
1 Hi
2
3 I wrote a little c++ program. It works fine if I compile it on my machine.
4 But now I want to statically link everything so I can run the program on
5 other some other arches. Where there might be no xerces-c for example
6 (OpenBSD)
7
8 g++ -g -Wall `curl-config --cflags` `curl-config --libs` -l xerces-c Ui.cpp
9 GetDataCurl.cpp GetDataAmazon.cpp XmlParser.cpp Options.cpp
10
11 works fine as soon as I add the -static flag for g++
12
13 g++ -g -Wall -static `curl-config --cflags` `curl-config --libs` -l
14 xerces-c Ui.cpp GetDataCurl.cpp GetDataAmazon.cpp XmlParser.cpp
15 Options.cpp /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.1/../../../../x86_64-pc-linux-gnu/bin/ld:
16 cannot find -lgssapi_krb5
17 collect2: ld returned 1 exit status
18
19 Any ideas
20
21 ldconfig -p | grep gssapi_krb5
22 libgssapi_krb5.so.2 (libc6,x86-64) => /usr/lib64/libgssapi_krb5.so.2
23 libgssapi_krb5.so (libc6,x86-64) => /usr/lib64/libgssapi_krb5.so
24
25
26 (Yes, I use a Makefile but it is easier to understand this way)
27
28 Cheers Dietger
29
30 ----
31 www.ribalba.de

Replies

Subject Author
Re: [gentoo-dev] g++ problem Robert Clark <hyakuhei@g.o>
Re: [gentoo-dev] g++ problem Mike Frysinger <vapier@g.o>