openbsd-ports/telephony/kamailio/patches/patch-Makefile_defs

81 lines
2.6 KiB
Plaintext

$OpenBSD: patch-Makefile_defs,v 1.4 2012/12/02 22:18:21 jasper Exp $
--- Makefile.defs.orig Thu Aug 2 07:54:15 2012
+++ Makefile.defs Sun Dec 2 14:41:06 2012
@@ -349,9 +349,9 @@ ppc_macros= __powerpc __powerpc__ __POWERPC__ __ppc__
ppc64_macros= __ppc64__ _ARCH_PPC64
mips_macros= __mips__ __mips _MIPS_ARCH_MIPS1
-mips2_macros= _MIPS_ISA_MIPS2 _MIPS_ISA_MIPS3 _MIPS_ISA_MIPS4 \
+mips2_macros= _MIPS_ISA_MIPS2 _MIPS_ISA_MIPS4 \
_MIPS_ARCH_MIPS2 _MIPS_ARCH_MIPS3 _MIPS_ARCH_MIPS4
-mips64_macros= _MIPS_ISA_MIPS64 _MIPS_ARCH_MIPS64
+mips64_macros= _MIPS_ISA_MIPS64 _MIPS_ARCH_MIPS64 _MIPS_ISA_MIPS3
alpha_macros= __alpha__ __alpha _M_ALPHA_
@@ -422,7 +422,7 @@ endif
endif
# dirs
-cfg_dir = etc/$(MAIN_NAME)/
+cfg_dir = share/examples/$(MAIN_NAME)/
bin_dir = sbin/
share_dir = share/$(MAIN_NAME)/
# lib/$(MAIN_NAME)/modules , lib/$(MAIN_NAME)/modules-s, lib/$(MAIN_NAME)/modules-k
@@ -504,7 +504,7 @@ data_prefix = $(basedir)$(prefix)
# target dirs for various stuff
-cfg_target = $(prefix)/$(cfg_dir)
+cfg_target = $(SYSCONFDIR)/$(MAIN_NAME)/
bin_target = $(prefix)/$(bin_dir)
#modules_target = $(prefix)/$(modules_dir)
lib_target = $(prefix)/$(lib_dir)
@@ -944,7 +944,7 @@ ifeq ($(ARCH), x86_64)
ifeq ($(CC_NAME), gcc)
C_DEFS+=-DCC_GCC_LIKE_ASM
#common stuff
- CFLAGS=-g -O9 -funroll-loops -Wcast-align $(PROFILE)
+ CFLAGS=
#if gcc 4.5+
# don't add '-mtune=$(CPU)' - gcc failure
ifeq ($(CC_SHORTVER), 4.5+)
@@ -958,12 +958,8 @@ else
#if gcc 4.2+
ifeq ($(CC_SHORTVER), 4.2+)
$(call set_if_empty,CPU,opteron)
- CFLAGS+=-m64 -minline-all-stringops \
- -falign-loops \
- -ftree-vectorize \
- -fno-strict-overflow \
- -mtune=$(CPU)
- LDFLAGS+=-m64
+ CFLAGS+=
+ LDFLAGS+=
else
#if gcc 4.0+
ifeq ($(CC_SHORTVER), 4.x)
@@ -1376,7 +1372,7 @@ ifeq ($(CC_NAME), gcc)
CFLAGS= -mips64 -O9 -funroll-loops $(PROFILE)
#if gcc 4.5+ or 4.2+
ifeq (,$(strip $(filter-out 4.2+ 4.5+,$(CC_SHORTVER))))
- CFLAGS+=-minline-all-stringops -ftree-vectorize \
+ CFLAGS+=-ftree-vectorize \
-fno-strict-overflow
else
#if gcc 4.0+
@@ -1904,9 +1900,10 @@ endif
ifeq ($(OS), openbsd)
C_DEFS+=-DHAVE_SOCKADDR_SA_LEN -DHAVE_GETHOSTBYNAME2 \
- -DHAVE_UNION_SEMUN -DHAVE_MSGHDR_MSG_CONTROL \
- -DHAVE_CONNECT_ECONNRESET_BUG -DHAVE_TIMEGM \
- -DHAVE_NETINET_IN_SYSTM -DUSE_SIGWAIT
+ -DHAVE_UNION_SEMUN -DHAVE_SCHED_YIELD \
+ -DHAVE_MSGHDR_MSG_CONTROL -DHAVE_CONNECT_ECONNRESET_BUG \
+ -DHAVE_TIMEGM -DHAVE_NETINET_IN_SYSTM \
+ -DUSE_SIGWAIT
ifneq ($(found_lock_method), yes)
C_DEFS+= -DUSE_PTHREAD_MUTEX # try pthread sems
found_lock_method=yes