freebsd-ports/devel/adime/files/patch-misc-makefile.uni
Pav Lucistnik 92b67b5ed4 Adime is a portable add-on library for Allegro with functions for generating
Allegro dialogs in a very simple way. Its main purpose is to give as easy an
API as possible to people who want dialogs for editing many kinds of input
data.

PR:		ports/85165
Submitted by:	Alejandro Pulver <alejandro@varnet.biz>
2005-09-16 20:41:59 +00:00

45 lines
1.3 KiB
Text

--- misc/makefile.uni.orig Fri Sep 10 16:34:54 2004
+++ misc/makefile.uni Sat Aug 20 13:45:44 2005
@@ -118,16 +118,6 @@
WFLAGS = -Wall -Wno-unused
endif
-ifdef PGCC
-OFLAGS = -mcpu=pentium -O6 -ffast-math
-else
-ifdef PENTIUMONLY
-OFLAGS = -march=pentium -O2 -funroll-loops -ffast-math
-else
-OFLAGS = -mcpu=pentium -O2 -funroll-loops -ffast-math
-endif
-endif
-
ifdef STATICLINK_ALLEGRO
ALLEGRO_CONFIG_FLAGS = --static
else
@@ -143,13 +133,14 @@
else
ifdef PROFILEMODE
# profiling build
-CFLAGS = $(WFLAGS) $(OFLAGS) -pg
+CFLAGS = $(WFLAGS) -pg
SFLAGS = $(WFLAGS)
LFLAGS += -pg
LIB_FLAGS = `allegro-config --libs profile $(ALLEGRO_CONFIG_FLAGS)`
else
# optimised build
-CFLAGS = $(WFLAGS) $(OFLAGS) -fomit-frame-pointer -fno-strength-reduce
+OPT = -O2 -ffast-math -fomit-frame-pointer -fno-strength-reduce
+CFLAGS = %%CFLAGS%% $(WFLAGS) -fPIC $(OPT) `allegro-config --cflags`
SFLAGS = $(WFLAGS)
ifndef SYMBOLMODE
LFLAGS += -s
@@ -168,7 +159,7 @@
CFLAGS += -D_ADIME_FORTIFY=1 -DFORTIFY
endif
-CFLAGS_NO_OPTIMIZE = $(WFLAGS)
+CFLAGS_NO_OPTIMIZE = $(WFLAGS) -fPIC `allegro-config --cflags`
COMPILE_FLAGS = $(subst src/,-DADIME_SRC ,$(findstring src/, $<))$(CFLAGS)
COMPILE_FLAGS_NO_OPTIMIZE = $(subst src/,-DADIME_SRC ,$(findstring src/, $<))$(CFLAGS_NO_OPTIMIZE)