From: Török E. <edw...@gm...> - 2010-02-26 14:26:48
|
On 02/26/2010 04:19 PM, Dan Nicholson wrote: > 2010/2/25 Török Edvin <edw...@gm...>: >> --- >> progs/glsl/Makefile | 2 +- >> 1 files changed, 1 insertions(+), 1 deletions(-) >> >> diff --git a/progs/glsl/Makefile b/progs/glsl/Makefile >> index 8928c83..aaa54cb 100644 >> --- a/progs/glsl/Makefile >> +++ b/progs/glsl/Makefile >> @@ -16,7 +16,7 @@ LIBS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLEW_LIB) -l$(GLU_LIB) \ >> # using : to avoid APP_CC pointing to CC loop >> CC := $(APP_CC) >> CFLAGS := -I$(INCDIR) $(CFLAGS) >> -LDLIBS = $(LIBS) >> +LDLIBS = $(LIBS) $(ARCH_FLAGS) > > Can you show the error you're getting? This should already be handled > in CFLAGS, but I suspect using make's implicit rules is causing this > problem. CFLAGS is not used when linking .o files only, so the command-line doesn't have -m32 at all: gcc array.o shaderutil.o readtex.o -L../../lib32 -lglut -lGLEW -lGLU -lGL -lm -o array /usr/bin/ld: skipping incompatible ../../lib32/libglut.so when searching for -lglut /usr/bin/ld: cannot find -lglut collect2: ld returned 1 exit status And with that patch applied it correctly adds -m32 to the commandline and links: gcc array.o shaderutil.o readtex.o -L../../lib32 -lglut -lGLEW -lGLU -lGL -lm -m32 -o array Best regards, --Edwin |