1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-23 00:43:28 +00:00

- Try to fix build on ia64 by explicitly including sys/types.h before

sys/systm.h
- Try to fix build on powerpc by turning off altivec optimizations,
  which the system compiler does not support yet

Obtained from:	pointyhat error logs
Suggested by:	kwm
This commit is contained in:
Rene Ladan 2010-10-22 23:50:58 +00:00
parent 14e850780f
commit 763f50c8c4
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=263461
4 changed files with 59 additions and 2 deletions

View File

@ -58,7 +58,7 @@ PLIST_SUB+= X11="@comment "
.endif
.if ${OSVERSION} >= 700042 && (${ARCH} == i386 || ${ARCH} == amd64)
CFLAGS+= -mtune=native
CFLAGS+= -mtune=native # comment out if world is built with clang and port with gcc
.endif
CXXFLAGS+= ${CFLAGS}

View File

@ -1,5 +1,5 @@
--- client/Makefile.am.orig 2008-09-10 00:43:08.000000000 +0200
+++ client/Makefile.am 2009-09-09 22:50:54.000000000 +0200
+++ client/Makefile.am 2010-10-22 22:54:44.000000000 +0200
@@ -50,12 +50,7 @@
@ -14,3 +14,24 @@
seti_boinc_SOURCES = \
main.cpp \
@@ -158,15 +153,16 @@
if PPC
# allow use of altivec instructions on PPC
+# unfortunately our system gcc is too old, so disable altivec
seti_boinc-analyzeFuncs_altivec.o: vector/analyzeFuncs_altivec.cpp
if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(seti_boinc_CXXFLAGS) $(CXXFLAGS) -DUSE_ALTIVEC \
- -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -faltivec \
+ $(CPPFLAGS) $(seti_boinc_CXXFLAGS) $(CXXFLAGS) \
+ -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \
-c -o $@ $<; then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \
else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
seti_boinc-analyzeFuncs_vector.o: vector/analyzeFuncs_vector.cpp
if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(seti_boinc_CXXFLAGS) $(CXXFLAGS) -DUSE_ALTIVEC \
+ $(CPPFLAGS) $(seti_boinc_CXXFLAGS) $(CXXFLAGS) \
-MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" \
-c -o $@ $<; then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; \
else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi

View File

@ -0,0 +1,10 @@
--- client/vector/hires_timer.cpp.orig 2008-09-09 18:55:19.000000000 +0200
+++ client/vector/hires_timer.cpp 2010-10-23 00:05:28.000000000 +0200
@@ -56,6 +56,7 @@
#include <sys/param.h>
#endif
#ifdef HAVE_SYS_SYSTM_H
+#include <sys/types.h>
#include <sys/systm.h>
#endif
#ifdef HAVE_MACHINE_CPU_H

View File

@ -0,0 +1,26 @@
--- m4/optimizations.m4.orig 2008-09-10 01:46:12.000000000 +0200
+++ m4/optimizations.m4 2010-10-22 23:30:38.000000000 +0200
@@ -98,15 +98,15 @@
if test x_$enable_altivec = x_yes ; then
AC_DEFINE_UNQUOTED([USE_ALTIVEC],[1],
- [Define to 1 if you want to use ALTIVEC optimizations])
+ [Define to 1 if you want to use ALTIVEC optimizations, disabled in this port])
# put compiler specific flags here
- if test x_$ac_cv_c_compiler_gnu = x_yes ; then
- SAH_CHECK_CFLAG([-faltivec],[CFLAGS="-faltivec ${CFLAGS}"])
- SAH_CHECK_CFLAG([-maltivec],[CFLAGS="-maltivec ${CFLAGS}"])
- SAH_CHECK_CFLAG([-mtune=G5],[CFLAGS="-mtune=G5 ${CFLAGS}"])
- SAH_CHECK_CFLAG([-mcpu=powerpc],[CFLAGS="-mcpu=powerpc ${CFLAGS}"])
- SAH_CHECK_LDFLAG([-framework Accelerate],[LDFLAGS="${LDFLAGS} -framework Accelerate"])
- fi
+# if test x_$ac_cv_c_compiler_gnu = x_yes ; then
+# SAH_CHECK_CFLAG([-faltivec],[CFLAGS="-faltivec ${CFLAGS}"])
+# SAH_CHECK_CFLAG([-maltivec],[CFLAGS="-maltivec ${CFLAGS}"])
+# SAH_CHECK_CFLAG([-mtune=G5],[CFLAGS="-mtune=G5 ${CFLAGS}"])
+# SAH_CHECK_CFLAG([-mcpu=powerpc],[CFLAGS="-mcpu=powerpc ${CFLAGS}"])
+# SAH_CHECK_LDFLAG([-framework Accelerate],[LDFLAGS="${LDFLAGS} -framework Accelerate"])
+# fi
fi
fi