From ff9f228b5faf905c8a948e0595a5956b17729ee0 Mon Sep 17 00:00:00 2001 From: Adrien Destugues Date: Sat, 2 Jun 2012 09:05:54 +0000 Subject: [PATCH] On Haiku, there are two different versions of gcc available (gcc2 and gcc4). Since mixing them in the same binary result in linker error, build them in separate dirs. git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1961 416bcca6-2ee7-4201-b75f-2eb2f807beb1 --- src/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Makefile b/src/Makefile index 3e4954b1..358f39bb 100644 --- a/src/Makefile +++ b/src/Makefile @@ -202,7 +202,9 @@ endif COPT = -W -Wall -c -g $(shell sdl-config --cflags) $(TTFCOPT) -I/boot/common/include $(LUACOPT) LOPT = $(shell sdl-config --libs) -lSDL_image -lpng -ljpeg -lz $(TTFLOPT) -lfreetype -lbe $(LUALOPT) CC = gcc - OBJDIR = ../obj/haiku + #Append the gcc kind to the objdir (gcc2 or gcc4) to avoid conflicts when switching from one to other. + OBJKIND = $(lastword $(shell setgcc)) + OBJDIR = ../obj/haiku/$(OBJKIND) ZIP = zip else