changeset 2465:c5d8bb3beb28

new packages: apr, apr-util, log4cxx
author Daniel Stonier <d.stonier@gmail.com>
date Wed, 02 May 2012 17:06:54 +1000
parents fc0830aafb54
children a7a203db74c5
files src/apr-util.mk src/apr.mk src/log4cxx-1-gcc.4.4.patch src/log4cxx-2-pkgconfig.patch src/log4cxx-3-warnings.patch src/log4cxx-4-mingw.definitions.patch src/log4cxx.mk
diffstat 7 files changed, 262 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/apr-util.mk	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,48 @@
+# This file is part of mingw-cross-env.
+# See doc/index.html for further information.
+
+# Special flags
+#
+# -no-undefined
+#
+# Can't find any documentation on this option 
+# (--no-undefined is there, but this aint!)
+# Anyway, it bombs when gcc tries to use it, 
+# but seems to help libtool at the final
+# linking stage. If its not there, then 
+# mingw aborts with unfound symbol errors.
+# That too is a problem, and maybe should 
+# resolved better than just by saying
+# -no-undefined.
+
+PKG             := apr-util
+$(PKG)_IGNORE   :=
+$(PKG)_VERSION  := 1.3.10
+$(PKG)_CHECKSUM := f5aaf15542209fee479679299dc4cb1ac0924a59
+$(PKG)_SUBDIR   := apr-util-$($(PKG)_VERSION)
+$(PKG)_FILE     := apr-util-$($(PKG)_VERSION).tar.gz
+$(PKG)_WEBSITE  := http://apr.apache.org/
+$(PKG)_URL      := http://mirror.apache-kr.org/apr/$($(PKG)_FILE)
+$(PKG)_URL_2    := http://apache.mirror.cdnetworks.com/apr/$($(PKG)_FILE)
+$(PKG)_DEPS     := gcc libiconv apr
+
+#define $(PKG)_UPDATE
+#    wget -q -O- 'http://www.ijg.org/' | \
+#    $(SED) -n 's,.*jpegsrc\.v\([0-9][^>]*\)\.tar.*,\1,p' | \
+#    head -1
+#endef
+
+define $(PKG)_BUILD
+    cd '$(1)' && ./configure \
+        --prefix='$(PREFIX)/$(TARGET)' \
+        --host='$(TARGET)' \
+        --disable-shared \
+        --enable-static \
+        --without-pgsql \
+        --without-sqlite2 \
+        --without-sqlite3 \
+        --with-apr='$(PREFIX)/$(TARGET)' \
+        CFLAGS=-D_WIN32_WINNT=0x0500 \
+        LDFLAGS=-no-undefined
+    $(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+endef
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/apr.mk	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,58 @@
+# This file is part of mingw-cross-env.
+# See doc/index.html for further information.
+
+# Special flags
+#
+# -no-undefined
+#
+# Can't find any documentation on this option 
+# (--no-undefined is there, but this aint!)
+# Anyway, it bombs when gcc tries to use it, 
+# but seems to help libtool at the final
+# linking stage. If its not there, then 
+# mingw aborts with unfound symbol errors.
+# That too is a problem, and maybe should 
+# resolved better than just by saying
+# -no-undefined.
+#
+# Type sizes
+#
+# Sometimes wine has an emulation environment which runs conf tests,
+# unfortunately these return like a 4^M, not 4 which breaks all the 
+# configure script logic.
+#    ac_cv_sizeof_off_t=4
+#    ac_cv_sizeof_pid_t=4 
+#    ac_cv_sizeof_size_t=4
+#    ac_cv_sizeof_ssize_t=4
+
+PKG             := apr
+$(PKG)_IGNORE   :=
+$(PKG)_VERSION  := 1.4.2
+$(PKG)_CHECKSUM := d48324efb0280749a5d7ccbb053d68545c568b4b
+$(PKG)_SUBDIR   := apr-$($(PKG)_VERSION)
+$(PKG)_FILE     := apr-$($(PKG)_VERSION).tar.gz
+$(PKG)_WEBSITE  := http://apr.apache.org/
+$(PKG)_URL      := http://mirror.apache-kr.org/apr/$($(PKG)_FILE)
+$(PKG)_URL_2    := http://apache.mirror.cdnetworks.com/apr/$($(PKG)_FILE)
+$(PKG)_DEPS     := gcc
+
+#define $(PKG)_UPDATE
+#    wget -q -O- 'http://www.ijg.org/' | \
+#    $(SED) -n 's,.*jpegsrc\.v\([0-9][^>]*\)\.tar.*,\1,p' | \
+#    head -1
+#endef
+
+define $(PKG)_BUILD
+    cd '$(1)' && ./configure \
+        --prefix='$(PREFIX)/$(TARGET)' \
+        --host='$(TARGET)' \
+        --disable-shared \
+        --enable-static \
+        ac_cv_sizeof_off_t=4 \
+        ac_cv_sizeof_pid_t=4 \
+        ac_cv_sizeof_size_t=4 \
+        ac_cv_sizeof_ssize_t=4 \
+        CFLAGS=-D_WIN32_WINNT=0x0500 \
+        LDFLAGS=-no-undefined
+    $(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+endef
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/log4cxx-1-gcc.4.4.patch	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,47 @@
+This file is part of mingw-cross-env.
+See doc/index.html for further information.
+
+These changes have already been applied to log4cxx trunk to update inclusions
+for recent gcc's.
+
+diff -NBaur vanilla/src/examples/cpp/console.cpp mingw_cross/src/examples/cpp/console.cpp
+--- vanilla/src/examples/cpp/console.cpp	2008-04-01 07:34:52.000000000 +0900
++++ mingw_cross/src/examples/cpp/console.cpp	2011-05-09 10:27:52.923808248 +0900
+@@ -15,6 +15,7 @@
+  * limitations under the License.
+  */
+ 
++#include <cstdio>
+ #include <stdlib.h>
+ #include <log4cxx/logger.h>
+ #include <log4cxx/consoleappender.h>
+@@ -22,6 +23,7 @@
+ #include <log4cxx/logmanager.h>
+ #include <iostream>
+ #include <locale.h>
++#include <string.h>
+ 
+ using namespace log4cxx;
+ using namespace log4cxx::helpers;
+diff -NBaur vanilla/src/main/cpp/inputstreamreader.cpp mingw_cross/src/main/cpp/inputstreamreader.cpp
+--- vanilla/src/main/cpp/inputstreamreader.cpp	2008-04-01 07:34:09.000000000 +0900
++++ mingw_cross/src/main/cpp/inputstreamreader.cpp	2011-05-09 10:27:27.991842868 +0900
+@@ -20,6 +20,7 @@
+ #include <log4cxx/helpers/exception.h>
+ #include <log4cxx/helpers/pool.h>
+ #include <log4cxx/helpers/bytebuffer.h>
++#include <string.h>
+ 
+ using namespace log4cxx;
+ using namespace log4cxx::helpers;
+diff -NBaur vanilla/src/main/cpp/socketoutputstream.cpp mingw_cross/src/main/cpp/socketoutputstream.cpp
+--- vanilla/src/main/cpp/socketoutputstream.cpp	2008-04-01 07:34:09.000000000 +0900
++++ mingw_cross/src/main/cpp/socketoutputstream.cpp	2011-05-09 10:27:27.999058156 +0900
+@@ -19,6 +19,7 @@
+ #include <log4cxx/helpers/socketoutputstream.h>
+ #include <log4cxx/helpers/socket.h>
+ #include <log4cxx/helpers/bytebuffer.h>
++#include <string.h>
+ 
+ using namespace log4cxx;
+ using namespace log4cxx::helpers;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/log4cxx-2-pkgconfig.patch	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,17 @@
+This file is part of mingw-cross-env.
+See doc/index.html for further information.
+
+This patch ensures that the correct dependencies can always be found for
+static mingw builds. Not yet submitted upstream.
+
+diff -NBaur vanilla/liblog4cxx.pc.in mingw_cross/liblog4cxx.pc.in
+--- vanilla/liblog4cxx.pc.in	2008-04-01 07:34:52.000000000 +0900
++++ mingw_cross/liblog4cxx.pc.in	2011-05-09 10:31:00.175584637 +0900
+@@ -20,6 +20,7 @@
+ Name: log4cxx
+ Description: log4cxx C++ logging framework
+ Version: @VERSION@
++Requires: apr-util-1, apr-1
+ Libs: -L${libdir} -llog4cxx
+ Cflags: -I${includedir}
+ 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/log4cxx-3-warnings.patch	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,20 @@
+This file is part of mingw-cross-env.
+See doc/index.html for further information.
+
+Already applied to log4cxx trunk.
+
+diff -NBaur vanilla/src/main/include/log4cxx/helpers/objectptr.h mingw_cross/src/main/include/log4cxx/helpers/objectptr.h
+--- vanilla/src/main/include/log4cxx/helpers/objectptr.h	2008-04-01 07:34:26.000000000 +0900
++++ mingw_cross/src/main/include/log4cxx/helpers/objectptr.h	2011-05-09 10:30:03.767560165 +0900
+@@ -28,9 +28,9 @@
+ //   switching between the initialization styles.
+ //
+ #if LOG4CXX_HELGRIND
+-#define _LOG4CXX_OBJECTPTR_INIT(x) { exchange(x); 
++#define _LOG4CXX_OBJECTPTR_INIT(x) : ObjectPtrBase() { exchange(x); 
+ #else
+-#define _LOG4CXX_OBJECTPTR_INIT(x) : p(x) {
++#define _LOG4CXX_OBJECTPTR_INIT(x) : ObjectPtrBase(), p(x) {
+ #endif
+ 
+ namespace log4cxx
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/log4cxx-4-mingw.definitions.patch	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,26 @@
+This file is part of mingw-cross-env.
+See doc/index.html for further information.
+
+Fixes a problem with the mismatched calling conventions in apr and log4cxx.
+See http://www.mail-archive.com/log4cxx-user@logging.apache.org/msg02671.html
+Not yet submitted upstream.
+
+diff -NBaur vanilla/src/main/include/log4cxx/helpers/thread.h mingw_cross/src/main/include/log4cxx/helpers/thread.h
+--- vanilla/src/main/include/log4cxx/helpers/thread.h	2008-04-01 07:34:26.000000000 +0900
++++ mingw_cross/src/main/include/log4cxx/helpers/thread.h	2011-05-09 11:08:23.123558232 +0900
+@@ -23,9 +23,13 @@
+ 
+ #if !defined(LOG4CXX_THREAD_FUNC)
+ #if defined(_WIN32)
+-#define LOG4CXX_THREAD_FUNC __stdcall
++  #if defined(__MINGW32__)
++    #define LOG4CXX_THREAD_FUNC
++  #else
++    #define LOG4CXX_THREAD_FUNC __stdcall
++  #endif
+ #else
+-#define LOG4CXX_THREAD_FUNC
++  #define LOG4CXX_THREAD_FUNC
+ #endif
+ #endif
+ 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/log4cxx.mk	Wed May 02 17:06:54 2012 +1000
@@ -0,0 +1,46 @@
+# This file is part of mingw-cross-env.
+# See doc/index.html for further information.
+
+# Special flags
+#
+# -no-undefined
+#
+# Can't find any documentation on this option 
+# (--no-undefined is there, but this aint!)
+# Anyway, it bombs when gcc tries to use it, 
+# but seems to help libtool at the final
+# linking stage. If its not there, then 
+# mingw aborts with unfound symbol errors.
+# That too is a problem, and maybe should 
+# resolved better than just by saying
+# -no-undefined.
+
+PKG             := log4cxx
+$(PKG)_IGNORE   :=
+$(PKG)_VERSION  := 0.10.0
+$(PKG)_CHECKSUM := d79c053e8ac90f66c5e873b712bb359fd42b648d
+$(PKG)_SUBDIR   := apache-log4cxx-$($(PKG)_VERSION)
+$(PKG)_FILE     := apache-log4cxx-$($(PKG)_VERSION).tar.gz
+$(PKG)_WEBSITE  := http://logging.apache.org/log4cxx/index.html
+$(PKG)_URL      := http://apache.naggo.co.kr//logging/log4cxx/0.10.0/$($(PKG)_FILE)
+$(PKG)_URL_2    := http://apache.mirror.cdnetworks.com//logging/log4cxx/0.10.0/$($(PKG)_FILE)
+$(PKG)_DEPS     := gcc apr-util
+
+#define $(PKG)_UPDATE
+#    wget -q -O- 'http://www.ijg.org/' | \
+#    $(SED) -n 's,.*jpegsrc\.v\([0-9][^>]*\)\.tar.*,\1,p' | \
+#    head -1
+#endef
+
+define $(PKG)_BUILD
+    cd '$(1)' && ./configure \
+        --prefix='$(PREFIX)/$(TARGET)' \
+        --host='$(TARGET)' \
+        --disable-shared \
+        --enable-static \
+        --with-apr='$(PREFIX)/$(TARGET)' \
+        --with-apr-util='$(PREFIX)/$(TARGET)' \
+        CFLAGS=-D_WIN32_WINNT=0x0500 \
+        CXXFLAGS=-D_WIN32_WINNT=0x0500 
+    $(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+endef