Static compilation of hello world
- From: Patricia Balbastre Betoret <patricia disca upv es>
- To: gtk-app-devel-list gnome org
- Subject: Static compilation of hello world
- Date: Thu, 19 Jun 2003 18:20:32 +0200
Hi!!
I want to build statically a simple Hello World program. I have compiled glib,
pango, atk and gtk with --enable-static, so I have all .a libraries. However,
I get this error when compiling:
gcc `pkg-config --libs --cflags gtk+-2.0` -static -o base-static
/usr/lib/gcc-lib/i386-linux/3.3/../../../crt1.o(.text+0x18): In function
`_start':
: undefined reference to `main'
collect2: ld returned 1 exit status
make: *** [static] Error 1
There is no problem when I compile without the static label:
gcc `pkg-config --libs --cflags gtk+-2.0` -o base base.c
I have read somewhere that static compilation does not work very well in gtk,
but I do not know why. I really need to make gtk applications static, so if
it will be impossible (or very difficult) in gtk, it will be better for me to
know it in advance before continue.
Thank you very much for your replies.
--
Patricia Balbastre Betoret
Departamento de Informatica de Sistemas y Computadores
Camino de Vera, 14, E-46071, Valencia, Spain
Tel: +34 96 387 70 00 Ext 75707
Fax: +34 96 387 75 79
http://ttt.upv.es/~patbalb1
-----------------------------
http://www.fsf.org/philosophy/no-word-attachments.es.html
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]