From: John Tytgat Date: Sun, 28 Sep 2008 20:35:57 +0000 (-0000) Subject: GCCSDK 4 build compatibility (not finished yet) X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=e32462efb87f60c00c2b487cd019ba4193388ab2;p=libsvgtiny.git GCCSDK 4 build compatibility (not finished yet) svn path=/trunk/libsvgtiny/; revision=5458 --- diff --git a/makefile b/makefile index 582a93b..89b83ae 100644 --- a/makefile +++ b/makefile @@ -16,30 +16,30 @@ ARFLAGS = cr INSTALL = install ifeq ($(TARGET),riscos) -GCCSDK_INSTALL_CROSSBIN ?= /home/riscos/cross/bin -GCCSDK_INSTALL_ENV ?= /home/riscos/env -CC = $(GCCSDK_INSTALL_CROSSBIN)/gcc -AR = $(GCCSDK_INSTALL_CROSSBIN)/ar -CFLAGS += -Driscos -mpoke-function-name -I$(GCCSDK_INSTALL_ENV)/include \ + GCCSDK_INSTALL_CROSSBIN ?= /home/riscos/cross/bin + GCCSDK_INSTALL_ENV ?= /home/riscos/env + CC := $(wildcard $(GCCSDK_INSTALL_CROSSBIN)/*gcc) + AR := $(wildcard $(GCCSDK_INSTALL_CROSSBIN)/*ar) + CFLAGS += -Driscos -mpoke-function-name -I$(GCCSDK_INSTALL_ENV)/include \ -I$(GCCSDK_INSTALL_ENV)/include/libxml2 -LIBS = -L$(GCCSDK_INSTALL_ENV)/lib -lxml2 -lz -EXEEXT ?= ,ff8 -PREFIX = $(GCCSDK_INSTALL_ENV) + LIBS = -L$(GCCSDK_INSTALL_ENV)/lib -lxml2 -lz + ifneq (,$(findstring arm-unknown-riscos-gcc,$(CC))) + EXEEXT := ,e1f + SUBTARGET := -elf- + else + EXEEXT := ,ff8 + SUBTARGET := -aof- + endif + PREFIX = $(GCCSDK_INSTALL_ENV) else -CFLAGS += -g `xml2-config --cflags` -fgnu89-inline -LIBS = `xml2-config --libs` -PREFIX = /usr/local + CFLAGS += -g `xml2-config --cflags` -fgnu89-inline + LIBS = `xml2-config --libs` + PREFIX = /usr/local endif -ifeq ($(TARGET),) -OBJDIR = objects -LIBDIR = lib -BINDIR = bin -else -OBJDIR = $(TARGET)-objects -LIBDIR = $(TARGET)-lib -BINDIR = $(TARGET)-bin -endif +OBJDIR = $(TARGET)$(SUBTARGET)objects +LIBDIR = $(TARGET)$(SUBTARGET)lib +BINDIR = $(TARGET)$(SUBTARGET)bin OBJS = $(addprefix $(OBJDIR)/, $(SOURCE:.c=.o))