Re: Compiling error gcc/g77 - MinGW

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jan Robbe wrote:

> I suppose I am missing a library or something. Does anybody has an
> idea what goes wrong? The path to the X11 (X-Window) libraries ist set
> in the environment variables. Maybe, the X11 libs are not complete?

Environment variables don't do anything; the compiler won't guess what
you want.  If you want to link against the X11 library you need to add
-lX11 (or whatever) to the link command.

> When compiling Xwin.c during the creation libPlt.a everything worked
> fine since the X11 libs, which were required by Xwin.c (Xlib.h,
> cursorfont.h, ..), could obviously be found.

That's incorrect logic.  Creating a static library does not involve any
linking, it's just a collection of object files in an archive.  They can
have any number of unresolved references.  You have to actually link
something in order to see undefined references.

Brian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux