[SDL] SDL 1.2.3 and cygwin under win98
brasse at ludd.luth.se
Sat Feb 16 12:55:01 PST 2002
I added -lcrtdll and that solved almost everything. Now i get this
In function `console_main':
/home/hercules/SDL-1.2.3/src/main/SDL_main.c:227: undefined reference to
collect2: ld returned 1 exit status
make: *** [pong] Error 1
This is strange for two reasons... 1) /home/hercules does not exist on
my system and 2) I have a SDL_main(int, char**) function in main.cpp
which compiles to main.o.
Any clues? My Makefile is attached.
nwagenaar at digitaldynamics.nl wrote:
> I had this problem also in the beginning but I've managed to fix
> this in a rather non-standard way.
> When I want to compile a WIN32 version of my SDL program and I want
> to use console output (which standard is not done but put in the
> stdout.txt and stderr.txt files) I use the following in my Makefile:
> LIBS = -Dmain=SDL_main -L/lib/mingw -lcygwin -lSDLmain -lSDL -lwinmm
> -lmsvcrt -lcrtdll
> If I want to use stdout.txt and stderr.txt I use the following :
> LIBS = -L/lib/mingw `/usr/local/bin/sdl-config --libs` -lcrtdll
> With the latest Cygwin update I get errors at undefined references with
> the CRT DLL so I use -lcrtdll (found in /lib/mingw) which solves it :)
> Also make sure you compile the sourcefiles using
> `/usr/local/bin/sdl-config --cflags`.
> This should work but I can't garrantee it ofcourse.
> Niels Wagenaar
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the SDL