summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTony Theodore <tonyt@logyst.com>2012-05-02 09:36:28 (GMT)
committerTony Theodore <tonyt@logyst.com>2012-05-02 09:36:28 (GMT)
commitfe2aea1a6d1b7ee05e3c18c4305c72f89f3843ec (patch)
tree29d041f38777fd6561b7bcd33312feebe4f64ec8
parent1940a74145dbbe86243068d63312667dd0b46111 (diff)
downloadmxe-fe2aea1a6d1b7ee05e3c18c4305c72f89f3843ec.zip
mxe-fe2aea1a6d1b7ee05e3c18c4305c72f89f3843ec.tar.gz
mxe-fe2aea1a6d1b7ee05e3c18c4305c72f89f3843ec.tar.bz2
packages apr, apr-util, log4cxx: various changes and add log4cxx test program
-rw-r--r--index.html15
-rw-r--r--src/apr-util.mk41
-rw-r--r--src/apr.mk49
-rw-r--r--src/log4cxx-1-gcc.4.4.patch2
-rw-r--r--src/log4cxx-2-pkgconfig.patch2
-rw-r--r--src/log4cxx-3-warnings.patch2
-rw-r--r--src/log4cxx-4-mingw.definitions.patch2
-rw-r--r--src/log4cxx-test.cpp33
-rw-r--r--src/log4cxx.mk37
9 files changed, 90 insertions, 93 deletions
diff --git a/index.html b/index.html
index 886be27..019cf1c 100644
--- a/index.html
+++ b/index.html
@@ -914,6 +914,16 @@ USE_OSGPLUGIN(&lt;plugin2&gt;)
<td id="agg-website"><a href="http://www.antigrain.com/">Anti-Grain Geometry</a></td>
</tr>
<tr>
+ <td id="apr-util-package">apr-util</td>
+ <td id="apr-util-version">1.3.10</td>
+ <td id="apr-util-website"><a href="http://apr.apache.org/">APR-util</a></td>
+ </tr>
+ <tr>
+ <td id="apr-package">apr</td>
+ <td id="apr-version">1.4.2</td>
+ <td id="apr-website"><a href="http://apr.apache.org/">APR</a></td>
+ </tr>
+ <tr>
<td id="atk-package">atk</td>
<td id="atk-version">2.2.0</td>
<td id="atk-website"><a href="http://www.gtk.org/">ATK</a></td>
@@ -1524,6 +1534,11 @@ USE_OSGPLUGIN(&lt;plugin2&gt;)
<td id="llvm-website"><a href="http://llvm.org/">llvm</a></td>
</tr>
<tr>
+ <td id="log4cxx-package">log4cxx</td>
+ <td id="log4cxx-version">0.10.0</td>
+ <td id="log4cxx-website"><a href="http://logging.apache.org/log4cxx/">log4cxx</a></td>
+ </tr>
+ <tr>
<td id="lua-package">lua</td>
<td id="lua-version">5.2.0</td>
<td id="lua-website"><a href="http://www.lua.org/">Lua</a></td>
diff --git a/src/apr-util.mk b/src/apr-util.mk
index 7c02066..5cb542e 100644
--- a/src/apr-util.mk
+++ b/src/apr-util.mk
@@ -1,48 +1,33 @@
-# This file is part of mingw-cross-env.
+# This file is part of mxe.
# 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)_IGNORE := 1.4.1
$(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
+$(PKG)_URL_2 := http://archive.apache.org/dist/apr/$($(PKG)_FILE)
+$(PKG)_DEPS := gcc apr expat libiconv
-#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)_UPDATE
+ wget -q -O- 'http://apr.apache.org/download.cgi' | \
+ grep 'aprutil1.*best' |
+ $(SED) -n 's,.*APR-util \([0-9.]*\).*,\1,p'
+endef
define $(PKG)_BUILD
cd '$(1)' && ./configure \
--prefix='$(PREFIX)/$(TARGET)' \
--host='$(TARGET)' \
+ --build="`config.guess`" \
--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=
+ CFLAGS=-D_WIN32_WINNT=0x0500
+ $(MAKE) -C '$(1)' -j 1 install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+ ln -sf '$(PREFIX)/$(TARGET)/bin/apu-1-config' '$(PREFIX)/bin/$(TARGET)-apu-1-config'
endef
diff --git a/src/apr.mk b/src/apr.mk
index 7f4a425..4ef8a6b 100644
--- a/src/apr.mk
+++ b/src/apr.mk
@@ -1,58 +1,33 @@
-# This file is part of mingw-cross-env.
+# This file is part of mxe.
# 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)_IGNORE := 1.4.6
$(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)_URL_2 := http://archive.apache.org/dist/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)_UPDATE
+ wget -q -O- 'http://apr.apache.org/download.cgi' | \
+ grep 'apr1.*best' |
+ $(SED) -n 's,.*APR \([0-9.]*\).*,\1,p'
+endef
define $(PKG)_BUILD
cd '$(1)' && ./configure \
--prefix='$(PREFIX)/$(TARGET)' \
--host='$(TARGET)' \
+ --build="`config.guess`" \
--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=
+ CFLAGS=-D_WIN32_WINNT=0x0500
+ $(MAKE) -C '$(1)' -j 1 install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+ ln -sf '$(PREFIX)/$(TARGET)/bin/apr-1-config' '$(PREFIX)/bin/$(TARGET)-apr-1-config'
endef
diff --git a/src/log4cxx-1-gcc.4.4.patch b/src/log4cxx-1-gcc.4.4.patch
index d1d9b16..b23fe53 100644
--- a/src/log4cxx-1-gcc.4.4.patch
+++ b/src/log4cxx-1-gcc.4.4.patch
@@ -1,4 +1,4 @@
-This file is part of mingw-cross-env.
+This file is part of MXE.
See doc/index.html for further information.
These changes have already been applied to log4cxx trunk to update inclusions
diff --git a/src/log4cxx-2-pkgconfig.patch b/src/log4cxx-2-pkgconfig.patch
index a322568..c66f1e9 100644
--- a/src/log4cxx-2-pkgconfig.patch
+++ b/src/log4cxx-2-pkgconfig.patch
@@ -1,4 +1,4 @@
-This file is part of mingw-cross-env.
+This file is part of MXE.
See doc/index.html for further information.
This patch ensures that the correct dependencies can always be found for
diff --git a/src/log4cxx-3-warnings.patch b/src/log4cxx-3-warnings.patch
index c7f0890..c6a65fc 100644
--- a/src/log4cxx-3-warnings.patch
+++ b/src/log4cxx-3-warnings.patch
@@ -1,4 +1,4 @@
-This file is part of mingw-cross-env.
+This file is part of MXE.
See doc/index.html for further information.
Already applied to log4cxx trunk.
diff --git a/src/log4cxx-4-mingw.definitions.patch b/src/log4cxx-4-mingw.definitions.patch
index 2e1b1eb..2d83c92 100644
--- a/src/log4cxx-4-mingw.definitions.patch
+++ b/src/log4cxx-4-mingw.definitions.patch
@@ -1,4 +1,4 @@
-This file is part of mingw-cross-env.
+This file is part of MXE.
See doc/index.html for further information.
Fixes a problem with the mismatched calling conventions in apr and log4cxx.
diff --git a/src/log4cxx-test.cpp b/src/log4cxx-test.cpp
new file mode 100644
index 0000000..460ee33
--- /dev/null
+++ b/src/log4cxx-test.cpp
@@ -0,0 +1,33 @@
+/*
+ * This file is part of MXE.
+ * See index.html for further information.
+ */
+
+#include <cstdlib>
+#include "log4cxx/logger.h"
+#include "log4cxx/basicconfigurator.h"
+#include "log4cxx/helpers/exception.h"
+
+using namespace log4cxx;
+using namespace log4cxx::helpers;
+
+LoggerPtr logger(Logger::getLogger("MXE"));
+
+int main(int argc, char **argv)
+{
+ (void)argc;
+ (void)argv;
+
+ int result = EXIT_SUCCESS;
+ try
+ {
+ BasicConfigurator::configure();
+ LOG4CXX_INFO(logger, "Hello World!");
+ }
+ catch(Exception&)
+ {
+ result = EXIT_FAILURE;
+ }
+
+ return result;
+}
diff --git a/src/log4cxx.mk b/src/log4cxx.mk
index b26bfaa..190759d 100644
--- a/src/log4cxx.mk
+++ b/src/log4cxx.mk
@@ -1,36 +1,20 @@
-# This file is part of mingw-cross-env.
+# This file is part of mxe.
# 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 := 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)_UPDATE
+ wget -q -O- 'http://logging.apache.org/log4cxx/download.html' | \
+ $(SED) -n 's,.*log4cxx-\([0-9.]*\)\.tar.*,\1,p' | \
+ head -1
+endef
define $(PKG)_BUILD
cd '$(1)' && ./configure \
@@ -41,6 +25,11 @@ define $(PKG)_BUILD
--with-apr='$(PREFIX)/$(TARGET)' \
--with-apr-util='$(PREFIX)/$(TARGET)' \
CFLAGS=-D_WIN32_WINNT=0x0500 \
- CXXFLAGS=-D_WIN32_WINNT=0x0500
+ CXXFLAGS=-D_WIN32_WINNT=0x0500
$(MAKE) -C '$(1)' -j '$(JOBS)' install bin_PROGRAMS= sbin_PROGRAMS= noinst_PROGRAMS= man_MANS=
+
+ '$(TARGET)-g++' \
+ -W -Wall -Werror -ansi -pedantic \
+ '$(2).cpp' -o '$(PREFIX)/$(TARGET)/bin/test-log4cxx.exe' \
+ `i686-pc-mingw32-pkg-config liblog4cxx --libs`
endef