JPEG Libs
Ian Porter
ian.porter3 at ntlworld.com
Thu Jan 23 20:11:40 GMT 2003
Hi all
I am going thought the tutorial for game programming on the web site.
http://www.gametutorials.com/
I have got a error with compiling the last of the tutorials which uses the
jpeg library, the error is below.
g++ -o BSP Main.o Init.o Camera.o Quake3Bsp.o Image.o `sdl-config --libs`
-L/usr/X11R6/lib -lGL -lGLU -lm -ljpeg
Image.o: In function `DecodeJPG(jpeg_decompress_struct*, tImage*)':
Image.o(.text+0x782): undefined reference to
`jpeg_read_header(jpeg_decompress_struct*, int)'
Image.o(.text+0x790): undefined reference to
`jpeg_start_decompress(jpeg_decompress_struct*)'
Image.o(.text+0x86d): undefined reference to
`jpeg_read_scanlines(jpeg_decompress_struct*, unsigned char**, unsigned)'
Image.o(.text+0x898): undefined reference to
`jpeg_finish_decompress(jpeg_decompress_struct*)'
Image.o: In function `LoadJPG(char const*)':
Image.o(.text+0x903): undefined reference to `jpeg_std_error(jpeg_error_mgr*)'
Image.o(.text+0x922): undefined reference to
`jpeg_CreateDecompress(jpeg_decompress_struct*, int, unsigned)'
Image.o(.text+0x93a): undefined reference to
`jpeg_stdio_src(jpeg_decompress_struct*, _IO_FILE*)'
Image.o(.text+0x977): undefined reference to
`jpeg_destroy_decompress(jpeg_decompress_struct*)'
collect2: ld returned 1 exit status
make: *** [BSP] Error 1
This is the makefile
CC = g++
TARGET = BSP
$(TARGET): Main.o Init.o Camera.o Quake3Bsp.o Image.o
$(CC) -o $(TARGET) Main.o Init.o Camera.o Quake3Bsp.o Image.o `sdl-config
--libs` -L/usr/X11R6/lib -lGL -lGLU -lm -ljpeg
Main.o: Main.cpp main.h Camera.h
$(CC) -c `sdl-config --cflags` Main.cpp
Init.o: Init.cpp main.h image.h
$(CC) -c `sdl-config --cflags` Init.cpp
Camera.o : Camera.cpp main.h Camera.h
$(CC) -c `sdl-config --cflags` Camera.cpp
Quake3Bsp.o : Quake3Bsp.cpp main.h Camera.h
$(CC) -c `sdl-config --cflags` Quake3Bsp.cpp
Image.o : Image.cpp image.h
$(CC) -c `sdl-config --cflags` Image.cpp
clean:
rm -f $(TARGET) Main.o Init.o Camera.o Quake3Bsp.o Image.o core
Any advice would be nice. I have done a search on the web and some one says
about having to recompile the jpeg sources with g++. How would I do this ?
Btw I am using Mandrake v9.0
Cheers
Ian
-
to unsubscribe from this list send an email to kdevelop-request at kdevelop.org with the following body:
unsubscribe »your-email-address«
More information about the KDevelop
mailing list