aboutsummaryrefslogtreecommitdiff
path: root/net/asterisk/files/patch-cdr::Makefile
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2006-01-17 22:27:45 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2006-01-17 22:27:45 +0000
commite61e1d66bd617141dc294a78d82e163554034060 (patch)
tree82d56db941093217a7c6bf1b3f6b2ba800639f4c /net/asterisk/files/patch-cdr::Makefile
parentcfb4ed733fa8c10b76f41592e5a4ea070e9ea37f (diff)
Update to 1.2.1.
Notes
Notes: svn path=/head/; revision=153765
Diffstat (limited to 'net/asterisk/files/patch-cdr::Makefile')
-rw-r--r--net/asterisk/files/patch-cdr::Makefile80
1 files changed, 47 insertions, 33 deletions
diff --git a/net/asterisk/files/patch-cdr::Makefile b/net/asterisk/files/patch-cdr::Makefile
index 1d0fb2049ba2..da16b609d5f2 100644
--- a/net/asterisk/files/patch-cdr::Makefile
+++ b/net/asterisk/files/patch-cdr::Makefile
@@ -1,51 +1,65 @@
---- cdr/Makefile.orig Tue Aug 31 23:33:00 2004
-+++ cdr/Makefile Tue Aug 9 17:28:11 2005
-@@ -21,7 +21,7 @@
- OSARCH=$(shell uname -s)
-
- ifeq (${OSARCH},FreeBSD)
--SOLINK+=-L/usr/local/lib
-+SOLINK+=-L$(LOCALBASE)/lib
+
+$FreeBSD$
+
+--- cdr/Makefile.orig Tue Nov 29 20:24:39 2005
++++ cdr/Makefile Thu Jan 12 17:56:23 2006
+@@ -21,8 +21,8 @@
+ endif
+
+ ifeq ($(findstring BSD,${OSARCH}),BSD)
+- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include
+- SOLINK+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib
++ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include
++ SOLINK+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib
endif
#The problem with sparc is the best stuff is in newer versions of gcc (post 3.0) only.
-@@ -37,18 +37,23 @@
+@@ -38,18 +38,18 @@
#
# unixODBC stuff...
#
-+ifdef WITH_ODBC
- MODS+=$(shell if [ -f "/usr/include/odbcinst.h" ]; then echo "cdr_odbc.so"; fi)
- MODS+=$(shell if [ -f "/usr/local/include/odbcinst.h" ]; then echo "cdr_odbc.so"; fi)
-+endif
+-ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/odbcinst.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/odbcinst.h),)
++ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/odbcinst.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/odbcinst.h),)
+ MODS+=cdr_odbc.so
+ endif
#
# FreeTDS stuff...
#
-+ifdef WITH_FREETDS
- MODS+=$(shell if [ -f "/usr/include/tds.h" ]; then echo "cdr_tds.so"; fi)
- MODS+=$(shell if [ -f "/usr/local/include/tds.h" ]; then echo "cdr_tds.so"; fi)
-+endif
-
+-ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/tds.h),)
+- ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/local/include/tdsver.h | grep -c 0.63),1)
++ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/tds.h)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tds.h),)
++ ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tdsver.h | grep -c 0.63),1)
+ CFLAGS += -DFREETDS_0_63
+ else
+- ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)/usr/local/include/tdsver.h | grep -c 0.62),1)
++ ifeq ($(shell grep -s TDS_VERSION_NO $(CROSS_COMPILE_TARGET)/usr/include/tdsver.h $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/tdsver.h | grep -c 0.62),1)
+ CFLAGS += -DFREETDS_0_62
+ else
+ CFLAGS += -DFREETDS_PRE_0_62
+@@ -61,7 +61,7 @@
#
# PGSQL stuff... Autoconf anyone??
#
-+ifdef WITH_PGSQL
- MODS+=$(shell if [ -d /usr/local/pgsql/include ] || [ -d /usr/include/pgsql ] || [ -d /usr/local/include/pgsql ] || [ -d /opt/pgsql/include ] || [ -f /usr/include/libpq-fe.h ] ; then echo "cdr_pgsql.so"; fi)
- CFLAGS+=$(shell if [ -d /usr/local/pgsql/include ]; then echo "-I/usr/local/pgsql/include"; fi)
- CFLAGS+=$(shell if [ -d /usr/include/pgsql ]; then echo "-I/usr/include/pgsql"; fi)
-@@ -62,16 +67,19 @@
- MLFLAGS+=$(shell if [ -d /usr/local/lib/pgsql ]; then echo "-L/usr/local/lib/pgsql"; fi)
- MLFLAGS+=$(shell if [ -d /opt/pgsql/lib ]; then echo "-L/opt/pgsql/lib"; fi)
- MLFLAGS+=$(shell if [ -f /usr/lib/libpq.so ]; then echo "-L/usr/lib"; fi)
-+endif
+-ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/postgresql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/libpq-fe.h),)
++ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/include/postgresql)$(wildcard $(CROSS_COMPILE_TARGET)/usr/local/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql)$(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include)$(wildcard $(CROSS_COMPILE_TARGET)/usr/include/libpq-fe.h),)
+ MODS+=cdr_pgsql.so
+ endif
- #
- # SQLIte stuff...
- #
-+ifdef WITH_SQLITE
- MODS+=$(shell if [ -f "/usr/include/sqlite.h" ]; then echo "cdr_sqlite.so"; fi)
-+endif
+@@ -82,9 +82,9 @@
+ MLFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/lib/pgsql
+ endif
+
+-ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/usr/local/include/pgsql),)
+- CFLAGS+=-I$(CROSS_COMPILE_TARGET)/usr/local/include/pgsql
+- MLFLAGS+=-L$(CROSS_COMPILE_TARGET)/usr/local/lib/pgsql
++ifneq ($(wildcard $(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql),)
++ CFLAGS+=-I$(CROSS_COMPILE_TARGET)$(LOCALBASE)/include/pgsql
++ MLFLAGS+=-L$(CROSS_COMPILE_TARGET)$(LOCALBASE)/lib/pgsql
+ endif
+ ifneq ($(wildcard $(CROSS_COMPILE_TARGET)/opt/pgsql/include),)
+@@ -110,7 +110,7 @@
all: depend $(MODS)
install: all