aboutsummaryrefslogtreecommitdiff
path: root/editors/libreoffice
diff options
context:
space:
mode:
Diffstat (limited to 'editors/libreoffice')
-rw-r--r--editors/libreoffice/Makefile27
-rw-r--r--editors/libreoffice/files/patch-solenv__gbuild__platform__unxgcc.mk16
-rw-r--r--editors/libreoffice/files/patch-solenv__inc__unxgcc.mk15
-rw-r--r--editors/libreoffice/files/patch__solenv__gbuild__platform__com_GCC_defs.mk18
4 files changed, 39 insertions, 37 deletions
diff --git a/editors/libreoffice/Makefile b/editors/libreoffice/Makefile
index d1a63345107c..57346e3e3d57 100644
--- a/editors/libreoffice/Makefile
+++ b/editors/libreoffice/Makefile
@@ -209,25 +209,22 @@ MANCOMPRESSED= yes
#USE_GCC= 4.6+
#DISTFILES+= bd30e9cf5523cdfc019b94f5e1d7fd19-cppunit-1.12.1.tar.gz:ext
#.else
-CONFIGURE_ARGS+= --with-system-cppunit
+.if defined(WITH_SYSTEM_CLANG)
+# XXX Clang PR13308 (http://llvm.org/bugs/show_bug.cgi?id=13308)
+# Fixed in r159895 (http://llvm.org/viewvc/llvm-project?view=rev&revision=159895)
+CC= /usr/bin/clang
+CXX= /usr/bin/clang++
+CXXCPP= /usr/bin/clang-cpp -x c++
+CPP= /usr/bin/clang-cpp
+.else
+BUILD_DEPENDS+= ${LOCALBASE}/bin/clang:${PORTSDIR}/lang/clang
+USE_BINUTILS= yes
CC= ${LOCALBASE}/bin/clang
CXX= ${LOCALBASE}/bin/clang++
CXXCPP= ${LOCALBASE}/bin/clang++ -E
CPP= ${LOCALBASE}/bin/clang -E
-# Work around a bug in pointyhat and tinderbox, prevent it to determine than
-# clang from ports is needed when host is a freebsd 9+
-#.if defined(PACKAGE_BUILDING)
-BUILD_DEPENDS+= ${LOCALBASE}/bin/clang:${PORTSDIR}/lang/clang
-USE_BINUTILS= yes
-#.endif
-#.if !exists(/usr/bin/clang)
-#BUILD_DEPENDS+= ${LOCALBASE}/bin/clang:${PORTSDIR}/lang/clang
-#USE_BINUTILS= yes
-#CXXCPP= clang++ -E
-#CPP= clang -E
-#.endif
-# XXX Work around C++11 problems with Clang.
-CXXFLAGS+= -std=gnu++0x -Qunused-arguments
+.endif
+CONFIGURE_ARGS+= --with-system-cppunit
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcppunit.so:${PORTSDIR}/devel/cppunit
#.endif
diff --git a/editors/libreoffice/files/patch-solenv__gbuild__platform__unxgcc.mk b/editors/libreoffice/files/patch-solenv__gbuild__platform__unxgcc.mk
index db22b1721460..8e297fb6f580 100644
--- a/editors/libreoffice/files/patch-solenv__gbuild__platform__unxgcc.mk
+++ b/editors/libreoffice/files/patch-solenv__gbuild__platform__unxgcc.mk
@@ -1,5 +1,17 @@
---- ./solenv/gbuild/platform/unxgcc.mk.orig 2012-03-27 18:22:01.000000000 +0200
-+++ ./solenv/gbuild/platform/unxgcc.mk 2012-04-16 14:24:48.000000000 +0200
+--- ./solenv/gbuild/platform/unxgcc.mk.orig 2012-05-22 08:48:18.000000000 -0400
++++ ./solenv/gbuild/platform/unxgcc.mk 2012-07-10 18:27:15.000000000 -0400
+@@ -58,10 +58,10 @@
+ gb_CXXFLAGS := \
+ $(gb_CXXFLAGS_COMMON) \
+ -fPIC \
+- -Wshadow \
+ -Wsign-promo \
+ -Woverloaded-virtual \
+ -Wno-non-virtual-dtor \
++ -Wno-unused-parameter \
+
+ ifeq ($(HAVE_GCC_VISIBILITY_FEATURE),TRUE)
+ gb_COMPILERDEFS += \
@@ -103,7 +103,7 @@
ifeq ($(HAVE_CXX0X),TRUE)
#Currently, as well as for its own merits, c++11/c++0x mode allows use to use
diff --git a/editors/libreoffice/files/patch-solenv__inc__unxgcc.mk b/editors/libreoffice/files/patch-solenv__inc__unxgcc.mk
index 834b6bfdbe77..4b7194bed627 100644
--- a/editors/libreoffice/files/patch-solenv__inc__unxgcc.mk
+++ b/editors/libreoffice/files/patch-solenv__inc__unxgcc.mk
@@ -1,5 +1,5 @@
---- ./solenv/inc/unxgcc.mk.orig 2012-03-27 18:22:01.000000000 +0200
-+++ ./solenv/inc/unxgcc.mk 2012-04-17 00:58:31.000000000 +0200
+--- ./solenv/inc/unxgcc.mk.orig 2012-05-22 08:48:18.000000000 -0400
++++ ./solenv/inc/unxgcc.mk 2012-07-10 18:28:23.000000000 -0400
@@ -78,7 +78,7 @@
# flags for the C++ Compiler
CFLAGSCC= -pipe $(ARCH_FLAGS)
@@ -18,3 +18,14 @@
.IF "$(GCCNUMVER)" <= "000400059999"
CFLAGSCXX+=-Wno-deprecated-declarations
.ENDIF
+@@ -136,8 +136,8 @@
+ # -Wshadow does not work for C with nested uses of pthread_cleanup_push:
+ CFLAGSWARNBOTH=-Wall -Wextra -Wendif-labels
+ CFLAGSWARNCC=$(CFLAGSWARNBOTH) -Wdeclaration-after-statement
+-CFLAGSWARNCXX=$(CFLAGSWARNBOTH) -Wshadow -Wno-ctor-dtor-privacy \
+- -Wno-non-virtual-dtor
++CFLAGSWARNCXX=$(CFLAGSWARNBOTH) -Wno-ctor-dtor-privacy \
++ -Wno-non-virtual-dtor -Wno-unused-parameter
+ CFLAGSWALLCC=$(CFLAGSWARNCC)
+ CFLAGSWALLCXX=$(CFLAGSWARNCXX)
+ CFLAGSWERRCC=-Werror -DLIBO_WERROR
diff --git a/editors/libreoffice/files/patch__solenv__gbuild__platform__com_GCC_defs.mk b/editors/libreoffice/files/patch__solenv__gbuild__platform__com_GCC_defs.mk
deleted file mode 100644
index f4b93931dd64..000000000000
--- a/editors/libreoffice/files/patch__solenv__gbuild__platform__com_GCC_defs.mk
+++ /dev/null
@@ -1,18 +0,0 @@
---- solenv/gbuild/platform/com_GCC_defs.mk.orig 2012-02-01 13:56:49.000000000 +0100
-+++ solenv/gbuild/platform/com_GCC_defs.mk 2012-03-01 08:38:34.634457577 +0100
-@@ -113,8 +113,13 @@
-
- gb_LinkTarget_EXCEPTIONFLAGS := \
- -DEXCEPTIONS_ON \
-- -fexceptions \
-- -fno-enforce-eh-specs \
-+ -fexceptions
-+
-+# Clang doesn't have this option
-+ifeq (,$(findstring /clang,$(CXX)))
-+gb_LinkTarget_EXCEPTIONFLAGS += \
-+ -fno-enforce-eh-specs
-+endif
-
- gb_LinkTarget_NOEXCEPTIONFLAGS := \
- -DEXCEPTIONS_OFF \