summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorobo <obo@openoffice.org>2010-06-22 16:02:44 +0200
committerobo <obo@openoffice.org>2010-06-22 16:02:44 +0200
commitd66343ab594fac375f4e3fc939594e9ebe5d4963 (patch)
treeb42e0b1f4044eb596050209047dfe935706a61fa
parenta1004a464f08acecd70fb8465532ef65aae58bd8 (diff)
parentf49fe0bfe93b4543e0b9f0819169f474dc9ad329 (diff)
CWS-TOOLING: integrate CWS mingwport30
Notes
split repo tag: libs-extern-sys_ooo/DEV300_m84 split repo tag: libs-extern-sys_ooo/OOO330_m0
-rw-r--r--berkeleydb/makefile.mk8
-rw-r--r--cairo/cairo/makefile.mk4
-rw-r--r--cairo/pixman/makefile.mk2
-rw-r--r--curl/makefile.mk6
-rw-r--r--graphite/makefile.mk4
-rw-r--r--hunspell/hunspell-mingw.patch12
-rw-r--r--hunspell/makefile.mk5
-rw-r--r--icu/makefile.mk1
-rw-r--r--[-rwxr-xr-x]libxml2/libxml2-mingw.patch24
-rw-r--r--libxml2/makefile.mk6
-rw-r--r--libxslt/libxslt-mingw.patch36
-rw-r--r--libxslt/makefile.mk7
-rw-r--r--python/makefile.mk1
13 files changed, 96 insertions, 20 deletions
diff --git a/berkeleydb/makefile.mk b/berkeleydb/makefile.mk
index 963c61a3bbde..325e8700e7a8 100644
--- a/berkeleydb/makefile.mk
+++ b/berkeleydb/makefile.mk
@@ -120,9 +120,9 @@ OUT2INC= \
CONFIGURE_DIR=out
#relative to CONFIGURE_DIR
# TODO needs clean up
-CFLAGS+=-nostdinc -D_MT
-db_CC=$(CC)
-db_CXX=$(CXX)
+CFLAGS+=-nostdinc
+db_CC=$(CC) -mthreads
+db_CXX=$(CXX) -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
db_CC+=-shared-libgcc
db_CXX+=-shared-libgcc
@@ -132,7 +132,7 @@ db_LDFLAGS=-no-undefined -L$(SOLARVER)/$(INPATH)/lib -L$(SOLARVER)/$(INPATH)/bin
db_LDFLAGS+=-L$(COMPATH)/lib/mingw -L$(COMPATH)/lib/w32api
.ENDIF
db_LDFLAGS+=-L$(COMPATH)/lib -L$(MINGW_CLIB_DIR)
-db_LIBS=-lmingwthrd
+db_LIBS=
.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
CFLAGS+=-D_GLIBCXX_DLL
db_LIBS+=-lstdc++_s
diff --git a/cairo/cairo/makefile.mk b/cairo/cairo/makefile.mk
index e0b12cc9f551..a29012892576 100644
--- a/cairo/cairo/makefile.mk
+++ b/cairo/cairo/makefile.mk
@@ -70,11 +70,9 @@ cairo_CPPFLAGS+=$(INCLUDE)
.IF "$(OS)"=="WNT"
# --------- Windows -------------------------------------------------
.IF "$(COM)"=="GCC"
-cairo_CFLAGS+=-D_MT
cairo_LDFLAGS+=-no-undefined -L$(ILIB:s/;/ -L/)
cairo_CPPFLAGS+=-nostdinc
-cairo_CC=$(CC)
-cairo_LIBS+=-lmingwthrd
+cairo_CC=$(CC) -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
cairo_CC+=-shared-libgcc
diff --git a/cairo/pixman/makefile.mk b/cairo/pixman/makefile.mk
index 20773c7597f8..f3c1c091639c 100644
--- a/cairo/pixman/makefile.mk
+++ b/cairo/pixman/makefile.mk
@@ -62,7 +62,7 @@ PATCH_FILES=..$/$(TARFILE_NAME).patch
.IF "$(COM)"=="GCC"
CONFIGURE_DIR=
CONFIGURE_ACTION=.$/configure
-CONFIGURE_FLAGS=--enable-static=yes --enable-shared=no --build=i586-pc-mingw32 --host=i586-pc-mingw32 CFLAGS="$(pixman_CFLAGS) -D_MT" LDFLAGS="$(pixman_LDFLAGS) -no-undefined -L$(ILIB:s/;/ -L/)" LIBS="-lmingwthrd" OBJDUMP="$(WRAPCMD) objdump"
+CONFIGURE_FLAGS=--enable-static=yes --enable-shared=no --build=i586-pc-mingw32 --host=i586-pc-mingw32 CFLAGS="$(pixman_CFLAGS) -mthreads" LDFLAGS="$(pixman_LDFLAGS) -no-undefined -L$(ILIB:s/;/ -L/)" OBJDUMP="$(WRAPCMD) objdump"
BUILD_ACTION=$(GNUMAKE)
BUILD_FLAGS+= -j$(EXTMAXPROCESS)
BUILD_DIR=$(CONFIGURE_DIR)
diff --git a/curl/makefile.mk b/curl/makefile.mk
index 1fab0c301bff..adab75f41d49 100644
--- a/curl/makefile.mk
+++ b/curl/makefile.mk
@@ -89,18 +89,18 @@ OUT2LIB=$(BUILD_DIR)$/.libs$/libcurl$(DLLPOST).4
.IF "$(GUI)"=="WNT"
.IF "$(COM)"=="GCC"
-curl_CC=$(CC)
+curl_CC=$(CC) -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
curl_CC+=-shared-libgcc
.ENDIF
-curl_LIBS=-lws2_32 -lwinmm -lmingwthrd
+curl_LIBS=-lws2_32 -lwinmm
.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
curl_LIBS+=-lstdc++_s
.ENDIF
CONFIGURE_DIR=.$/
#relative to CONFIGURE_DIR
CONFIGURE_ACTION=.$/configure
-CONFIGURE_FLAGS= --without-ssl --enable-ftp --enable-ipv6 --disable-http --disable-gopher --disable-file --disable-ldap --disable-telnet --disable-dict --build=i586-pc-mingw32 --host=i586-pc-mingw32 CC="$(curl_CC)" CPPFLAGS="$(INCLUDE)" OBJDUMP="objdump" CFLAGS=-D_MT LDFLAGS="-L$(ILIB:s/;/ -L/)" LIBS="$(curl_LIBS)"
+CONFIGURE_FLAGS= --without-ssl --enable-ftp --enable-ipv6 --disable-http --disable-gopher --disable-file --disable-ldap --disable-telnet --disable-dict --build=i586-pc-mingw32 --host=i586-pc-mingw32 CC="$(curl_CC)" CPPFLAGS="$(INCLUDE)" OBJDUMP="objdump" LDFLAGS="-L$(ILIB:s/;/ -L/)" LIBS="$(curl_LIBS)"
BUILD_DIR=$(CONFIGURE_DIR)$/lib
BUILD_ACTION=make
OUT2BIN=$(BUILD_DIR)$/.libs$/libcurl*.dll
diff --git a/graphite/makefile.mk b/graphite/makefile.mk
index 2f4ff2535442..471bc3c366d7 100644
--- a/graphite/makefile.mk
+++ b/graphite/makefile.mk
@@ -102,11 +102,11 @@ GR_LIB_PATH=
.IF "$(OS)"=="WNT"
PATCH_FILES+=graphite-2.3.1.patch.mingw
-EXTRA_GR_CXX_FLAGS=-nostdinc
+EXTRA_GR_CXX_FLAGS=-mthreads -nostdinc
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
EXTRA_GR_CXX_FLAGS+=-shared-libgcc
.ENDIF
-EXTRA_GR_LD_FLAGS+=-no-undefined
+EXTRA_GR_LD_FLAGS+=-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2
.ENDIF
# don't use SOLARLIB for LDFLAGS because it pulls in system graphite so build will fail
diff --git a/hunspell/hunspell-mingw.patch b/hunspell/hunspell-mingw.patch
new file mode 100644
index 000000000000..0120e01ddba1
--- /dev/null
+++ b/hunspell/hunspell-mingw.patch
@@ -0,0 +1,12 @@
+--- misc/hunspell-1.2.9/src/tools/hunspell.cxx 2010-02-27 23:37:14.000000000 +0900
++++ misc/build/hunspell-1.2.9/src/tools/hunspell.cxx 2010-04-25 07:57:39.233875000 +0900
+@@ -27,7 +27,9 @@
+
+ #ifdef WIN32
+
++#ifndef __MINGW32__
+ #define gettext
++#endif
+ #define LIBDIR "C:\\Hunspell\\"
+ #define USEROOODIR "Application Data\\OpenOffice.org 2\\user\\wordbook"
+ #define OOODIR \
diff --git a/hunspell/makefile.mk b/hunspell/makefile.mk
index f58204a33bc5..253607ab0c0f 100644
--- a/hunspell/makefile.mk
+++ b/hunspell/makefile.mk
@@ -71,8 +71,11 @@ OUT2LIB=$(BUILD_DIR)$/src$/hunspell$/.libs$/libhunspell-1.2.a
.IF "$(GUI)"=="WNT"
.IF "$(COM)"=="GCC"
+PATCH_FILES=\
+ hunspell-mingw.patch
+
CONFIGURE_ACTION=configure
-CONFIGURE_FLAGS= --disable-shared --with-pic
+CONFIGURE_FLAGS= --disable-shared --with-pic LDFLAGS=-Wl,--enable-runtime-pseudo-reloc-v2
BUILD_ACTION=make
OUT2LIB=$(BUILD_DIR)$/src$/hunspell$/.libs$/libhunspell-1.2.a
.ELSE
diff --git a/icu/makefile.mk b/icu/makefile.mk
index 70ff42c1a443..2fafcfa75e8d 100644
--- a/icu/makefile.mk
+++ b/icu/makefile.mk
@@ -158,6 +158,7 @@ icu_LIBS=-lmingwthrd
.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
icu_LIBS+=-lstdc++_s
.ENDIF
+icu_LDFLAGS+=-Wl,--enable-runtime-pseudo-reloc-v2
CONFIGURE_ACTION+=sh -c 'CFLAGS="-O -D_MT" CXXFLAGS="-O -D_MT" LDFLAGS="$(icu_LDFLAGS)" LIBS="$(icu_LIBS)" ./configure --build=i586-pc-mingw32 --enable-layout --enable-static --enable-shared=yes --enable-64bit-libs=no'
#CONFIGURE_FLAGS=--enable-layout --enable-static --enable-shared=yes --enable-64bit-libs=no
diff --git a/libxml2/libxml2-mingw.patch b/libxml2/libxml2-mingw.patch
index d160dcb70138..651b0c13f1bb 100755..100644
--- a/libxml2/libxml2-mingw.patch
+++ b/libxml2/libxml2-mingw.patch
@@ -9,6 +9,19 @@
*-*-cygwin*)
MODULE_EXTENSION=".dll"
{ $as_echo "$as_me:$LINENO: checking for dlopen in -lcygwin" >&5
+@@ -20632,11 +20636,10 @@
+
+ fi
+ case $host_os in
+- *mingw32*) if test "$THREAD_LIBS" != "-lpthread"; then
++ *mingw32*)
+ WITH_THREADS="1"
+ THREADS_W32="Win32"
+ THREAD_CFLAGS="$THREAD_CFLAGS -DHAVE_WIN32_THREADS"
+- fi
+ ;;
+ *cygwin*) THREAD_LIBS=""
+ ;;
--- misc/libxml2-2.7.6/libxml.h 2007-11-23 19:47:23.000000000 +0900
+++ misc/build/libxml2-2.7.6/libxml.h 2009-07-10 14:37:34.988250000 +0900
@@ -30,6 +30,10 @@
@@ -22,3 +35,14 @@
#include <libxml/xmlversion.h>
#endif
+--- misc/libxml2-2.7.6/include/libxml/xmlexports.h 2009-09-25 00:31:59.000000000 +0900
++++ misc/build/libxml2-2.7.6/include/libxml/xmlexports.h 2010-06-06 11:15:54.160750000 +0900
+@@ -113,7 +113,7 @@
+ * _imp__xmlFree listed as missing. Try to workaround the problem
+ * by also making that declaration when compiling client code.
+ */
+- #if !defined(LIBXML_STATIC)
++ #if defined(IN_LIBXML) && !defined(LIBXML_STATIC)
+ #define XMLPUBFUN __declspec(dllexport)
+ #define XMLPUBVAR __declspec(dllexport)
+ #else
diff --git a/libxml2/makefile.mk b/libxml2/makefile.mk
index 93275b65b2d8..555d87254ff8 100644
--- a/libxml2/makefile.mk
+++ b/libxml2/makefile.mk
@@ -55,17 +55,17 @@ PATCH_FILES=libxml2-configure.patch \
.IF "$(OS)"=="WNT"
.IF "$(COM)"=="GCC"
-xml2_CC=$(CC)
+xml2_CC=$(CC) -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
xml2_CC+=-shared-libgcc
.ENDIF
-xml2_LIBS=-lws2_32 -lmingwthrd
+xml2_LIBS=-lws2_32
.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
xml2_LIBS+=-lstdc++_s
.ENDIF
CONFIGURE_DIR=
CONFIGURE_ACTION=.$/configure
-CONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-zlib --enable-static=no --without-debug --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(xml2_CC)" CFLAGS=-D_MT LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc -L$(ILIB:s/;/ -L/)" LIBS="$(xml2_LIBS)" OBJDUMP="$(WRAPCMD) objdump"
+CONFIGURE_FLAGS=--enable-ipv6=no --without-python --without-zlib --enable-static=no --without-debug --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(xml2_CC)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2 -L$(ILIB:s/;/ -L/)" LIBS="$(xml2_LIBS)" OBJDUMP=objdump
BUILD_ACTION=$(GNUMAKE)
BUILD_DIR=$(CONFIGURE_DIR)
.ELSE
diff --git a/libxslt/libxslt-mingw.patch b/libxslt/libxslt-mingw.patch
new file mode 100644
index 000000000000..da8eee3b1098
--- /dev/null
+++ b/libxslt/libxslt-mingw.patch
@@ -0,0 +1,36 @@
+--- misc/libxslt-1.1.26/ltmain.sh 2010-06-06 14:43:28.785750000 +0900
++++ misc/build/libxslt-1.1.26/ltmain.sh 2010-06-06 15:14:26.176375000 +0900
+@@ -2983,15 +2983,7 @@
+ *mingw* )
+ lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
+ case $build in
+- *mingw* ) # actually, msys
+- # awkward: cmd appends spaces to result
+- lt_sed_strip_trailing_spaces="s/[ ]*\$//"
+- func_to_host_path_tmp1=`( cmd //c echo "$1" |\
+- $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
+- func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
+- $SED -e "$lt_sed_naive_backslashify"`
+- ;;
+- *cygwin* )
++ *cygwin* | *mingw* )
+ func_to_host_path_tmp1=`cygpath -w "$1"`
+ func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\
+ $SED -e "$lt_sed_naive_backslashify"`
+@@ -3062,15 +3054,7 @@
+ func_to_host_pathlist_tmp1=`echo "$func_to_host_pathlist_tmp2" |\
+ $SED -e 's|^:*||' -e 's|:*$||'`
+ case $build in
+- *mingw* ) # Actually, msys.
+- # Awkward: cmd appends spaces to result.
+- lt_sed_strip_trailing_spaces="s/[ ]*\$//"
+- func_to_host_pathlist_tmp2=`( cmd //c echo "$func_to_host_pathlist_tmp1" |\
+- $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""`
+- func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
+- $SED -e "$lt_sed_naive_backslashify"`
+- ;;
+- *cygwin* )
++ *cygwin* | *mingw* )
+ func_to_host_pathlist_tmp2=`cygpath -w -p "$func_to_host_pathlist_tmp1"`
+ func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\
+ $SED -e "$lt_sed_naive_backslashify"`
diff --git a/libxslt/makefile.mk b/libxslt/makefile.mk
index b3f9ed203653..1c9370bbe8ed 100644
--- a/libxslt/makefile.mk
+++ b/libxslt/makefile.mk
@@ -52,22 +52,23 @@ TARFILE_NAME=$(PRJNAME)-$(LIBXSLTVERSION)
TARFILE_MD5=e61d0364a30146aaa3001296f853b2b9
PATCH_FILES=libxslt-configure.patch \
libxslt-win_manifest.patch \
+ libxslt-mingw.patch \
libxslt-gnome602728.patch
# This is only for UNX environment now
.IF "$(OS)"=="WNT"
.IF "$(COM)"=="GCC"
-xslt_CC=$(CC)
+xslt_CC=$(CC) -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
xslt_CC+=-shared-libgcc
.ENDIF
-xslt_LIBS=-lmingwthrd
+xslt_LIBS=
.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
xslt_LIBS+=-lstdc++_s
.ENDIF
CONFIGURE_DIR=
CONFIGURE_ACTION=.$/configure
-CONFIGURE_FLAGS=--enable-ipv6=no --without-crypto --without-python --enable-static=no --with-sax1=yes --build=i586-pc-mingw32 --host=i586-pc-mingw32 CC="$(xslt_CC)" CFLAGS="$(xslt_CFLAGS) -D_MT" LDFLAGS="-no-undefined -L$(ILIB:s/;/ -L/)" LIBS="$(xslt_LIBS)" LIBXML2LIB=$(LIBXML2LIB) OBJDUMP="$(WRAPCMD) objdump"
+CONFIGURE_FLAGS=--without-crypto --without-python --enable-static=no --build=i586-pc-mingw32 --host=i586-pc-mingw32 CC="$(xslt_CC)" CFLAGS="$(xslt_CFLAGS)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2 -L$(ILIB:s/;/ -L/)" LIBS="$(xslt_LIBS)" LIBXML2LIB=$(LIBXML2LIB) OBJDUMP=objdump
BUILD_ACTION=chmod 777 xslt-config && $(GNUMAKE)
BUILD_FLAGS+= -j$(EXTMAXPROCESS)
BUILD_DIR=$(CONFIGURE_DIR)
diff --git a/python/makefile.mk b/python/makefile.mk
index 86d9835e8604..a35e596669a0 100644
--- a/python/makefile.mk
+++ b/python/makefile.mk
@@ -93,6 +93,7 @@ python_LDFLAGS=-mno-cygwin -mthreads
.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
python_LDFLAGS+=-shared-libgcc
.ENDIF
+python_LDFLAGS+=-shared-libgcc -Wl,--enable-runtime-pseudo-reloc-v2
CONFIGURE_ACTION=./configure --prefix=$(MYCWD)/python-inst --enable-shared CC="$(CC:s/guw.exe //)" CXX="$(CXX:s/guw.exe //)" MACHDEP=MINGW32 LN="cp -p" CFLAGS="$(python_CFLAGS)" LDFLAGS="$(python_LDFLAGS)"
BUILD_ACTION=$(ENV_BUILD) make && make install
.ELSE