Minor Makefile fixes for libpri (bug #2330)

git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@132 2fbb986a-6c06-0410-b554-c9c1f0a7f128
This commit is contained in:
Mark Spencer 2004-08-31 17:40:59 +00:00
parent 96535a0c17
commit 12155fa6c3

View File

@ -28,6 +28,7 @@
#LIBPRI_COUNTERS=-DLIBPRI_COUNTERS
OSARCH=$(shell uname -s)
PROC=$(shell uname -m)
TOBJS=testpri.o
T2OBJS=testprilib.o
@ -46,6 +47,14 @@ CFLAGS += -I../zaptel -I../zapata
endif
endif
#The problem with sparc is the best stuff is in newer versions of gcc (post 3.0) only.
#This works for even old (2.96) versions of gcc and provides a small boost either way.
#A ultrasparc cpu is really v9 but the stock debian stable 3.0 gcc doesnt support it.
ifeq ($(PROC),sparc64)
PROC=ultrasparc
CFLAGS += -mtune=$(PROC) -O3 -pipe -fomit-frame-pointer -mcpu=v8
endif
all: depend $(STATIC_LIBRARY) $(DYNAMIC_LIBRARY)
update:
@ -69,16 +78,16 @@ uninstall:
rm -f $(INSTALL_PREFIX)/usr/include/libpri.h
pritest: pritest.o
$(CC) -o pritest pritest.o -L. -lpri -lzap
$(CC) -o pritest pritest.o -L. -lpri -lzap $(CFLAGS)
testprilib.o: testprilib.c
$(CC) $(CFLAGS) -D_REENTRANT -D_GNU_SOURCE -o $@ -c $<
testprilib: testprilib.o
$(CC) -o testprilib testprilib.o -L. -lpri -lpthread
$(CC) -o testprilib testprilib.o -L. -lpri -lpthread $(CFLAGS)
pridump: pridump.o
$(CC) -o pridump pridump.o -L. -lpri -lzap
$(CC) -o pridump pridump.o -L. -lpri -lzap $(CFLAGS)
include .depend