From a2188457cf608cdc3c24e317cff82b7dd7a5f45a Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sun, 26 Apr 2015 14:11:32 +0100 Subject: Fix mingw libgnurx building for static libraries This uses the Fedora mingw-libgnurx package approach to make the autofoo in the gnurx library less broken allowing teh generation of static libraries. --- sdk/Makefile | 12 ++-- sdk/recipes/patches/libgnurx/authors.p | 4 ++ sdk/recipes/patches/libgnurx/configure.ac.p | 93 +++++++++++++++++++++++++++++ sdk/recipes/patches/libgnurx/makefile.am.p | 11 ++++ sdk/recipes/patches/libgnurx/news.p | 4 ++ 5 files changed, 120 insertions(+), 4 deletions(-) create mode 100644 sdk/recipes/patches/libgnurx/authors.p create mode 100644 sdk/recipes/patches/libgnurx/configure.ac.p create mode 100644 sdk/recipes/patches/libgnurx/makefile.am.p create mode 100644 sdk/recipes/patches/libgnurx/news.p diff --git a/sdk/Makefile b/sdk/Makefile index 234a434..09bba8a 100644 --- a/sdk/Makefile +++ b/sdk/Makefile @@ -195,15 +195,19 @@ $(SOURCEDIR)/libiconv-$(VERSION_LIBICONV).tar.gz: # libgnurx $(BUILDSTEPS)/libgnurx.d: $(BUILDSTEPS)/builddir.d $(BUILDSTEPS)/libgnurx-src.d - mkdir -p $(BUILDDIR)/libgnurx - cd $(BUILDDIR)/libgnurx && tar xaf $(SOURCEDIR)/libgnurx-$(VERSION_LIBGNURX).tar.gz - for p in `ls $(RECIPES)/patches/libgnurx/*.p` ; do $(PATCH) -d $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) -p0 <$$p ; done - cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) ./configure --prefix=$(GCCSDK_INSTALL_ENV) --target=$(TARGET) --host=$(TARGET) + cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) ./configure --prefix=$(GCCSDK_INSTALL_ENV) --target=$(TARGET) --host=$(TARGET) --enable-static --disable-shared cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) make cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) make install touch $@ $(BUILDSTEPS)/libgnurx-src.d: $(BUILDSTEPS)/sourcedir.d $(SOURCEDIR)/libgnurx-$(VERSION_LIBGNURX).tar.gz + mkdir -p $(BUILDDIR)/libgnurx + cd $(BUILDDIR)/libgnurx && tar xaf $(SOURCEDIR)/libgnurx-$(VERSION_LIBGNURX).tar.gz + for p in $$(ls $(RECIPES)/patches/libgnurx/*.p) ; do $(PATCH) -d $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) -p0 <$$p ; done + cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) libtoolize --copy + cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) aclocal + cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) autoconf + cd $(BUILDDIR)/libgnurx/mingw-libgnurx-$(VERSION_LIBGNURX) && $(env) automake --add-missing touch $@ $(SOURCEDIR)/libgnurx-$(VERSION_LIBGNURX).tar.gz: diff --git a/sdk/recipes/patches/libgnurx/authors.p b/sdk/recipes/patches/libgnurx/authors.p new file mode 100644 index 0000000..20c0eec --- /dev/null +++ b/sdk/recipes/patches/libgnurx/authors.p @@ -0,0 +1,4 @@ +--- oAUTHORS 1970-01-01 01:00:00.000000000 +0100 ++++ AUTHORS 2015-04-26 13:57:59.463226219 +0100 +@@ -0,0 +1 @@ ++empty diff --git a/sdk/recipes/patches/libgnurx/configure.ac.p b/sdk/recipes/patches/libgnurx/configure.ac.p new file mode 100644 index 0000000..628d979 --- /dev/null +++ b/sdk/recipes/patches/libgnurx/configure.ac.p @@ -0,0 +1,93 @@ +--- configure.ac.orig 2015-04-26 13:55:34.199166493 +0100 ++++ configure.ac 2015-04-26 13:56:50.633303028 +0100 +@@ -1,83 +1,12 @@ + # configure.ac -*- Autoconf -*- + # Process this file with autoconf, to generate a configure script. +-# +-# $Id: configure.ac,v 1.2 2007/05/03 22:46:09 keithmarshall Exp $ +-# +-# Copyright (C) 2007, MinGW Project +-# Written by Keith Marshall +-# +-# Package identification. +-# +-# This is configure.ac for the MinGW `libgnurx' package. +-# BASENAME, VERSION_MAJOR and VERSION_MINOR are required tags; +-# complete `Value' fields as appropriate. +-# +-# Tag Value +-# --------------- ---------- +- MINGW_AC_DEFINE_PACKAGE_ID([BASENAME], [libgnurx]) +- MINGW_AC_DEFINE_PACKAGE_ID([VERSION_MAJOR], [2]) +- MINGW_AC_DEFINE_PACKAGE_ID([VERSION_MINOR], [5]) +-# +-# PATCHLEVEL is optional; comment/uncomment and adjust as required. +-# +- MINGW_AC_DEFINE_PACKAGE_ID([PATCHLEVEL], [1]) +-# +-# DLL_VERSION is required; installed DLLs will be versioned, by +-# appending a hyphen, the specified tag value, and then the `.dll' +-# file name extension, to the base name of each generated DLL. +-# +- MINGW_AC_DEFINE_PACKAGE_ID([DLL_VERSION], [0]) +-# +-# +-# libgnurx is an adaptation of Tor Lillqvist's original port of the +-# regex functions from GNU libc, for use on native Woe32 platforms. +-# +-# The original sources, on which this port is based, remain copyright +-# of their respective authors, or of the Free Software Foundation Inc., +-# as indicated in individual file headers; all are redistributed with +-# permission, as granted by the GNU Lesser General Public License. +-# +-# This is free software. It is provided AS IS, in the hope that it may +-# be useful, but WITHOUT WARRANTY OF ANY KIND, not even an IMPLIED WARRANTY +-# of MERCHANTABILITY, nor of FITNESS FOR ANY PARTICULAR PURPOSE. +-# +-# Permission is granted to redistribute this software, either "as is" or +-# in modified form, under the terms of the GNU Lesser General Public License, +-# as published by the Free Software Foundation; either version 2.1, or (at +-# your option) any later version. +-# +-# You should have received a copy of the GNU Lesser General Public License +-# along with this software; see the file COPYING.LIB. If not, write to the +-# Free Software Foundation, 51 Franklin St - Fifth Floor, Boston, +-# MA 02110-1301, USA. + +-# Autoconf initialisation. +-# +- AC_PREREQ([2.59]) +- AC_INIT(__MINGW_AC_PACKAGE_IDENTIFICATION__) ++AC_INIT(libgnurx, 2.5.1) ++AM_INIT_AUTOMAKE ++AC_PROG_INSTALL ++AC_LIBTOOL_DLOPEN ++AC_LIBTOOL_WIN32_DLL ++AC_PROG_LIBTOOL + +-# Compiler and build tool checks. +-# +- AC_PROG_CC +- MINGW_AC_PROG_CC_OPTIONS([CC_QUALIFIED], [-m], [threads tune=pentium3]) ++AC_OUTPUT([Makefile]) + +-# Set the release version for the resultant DLL. +-# +- AC_SUBST([DLLVERSION], [__MINGW_AC_PACKAGE_DLL_VERSION__]) +- +-# User configuration options. +-# +- MINGW_AC_DISTRIBUTION_TYPE([tar]) +- MINGW_AC_MSVC_IMPORT_LIBS([GNURX_LIB], [gnurx.lib]) +- MINGW_AC_DEV_INSTALL_OPTION +- +-# Configuration output. +-# +- AC_SUBST([GNURX_LIB]) +- AC_SUBST([CC_QUALIFIED], ["$CC $CC_QUALIFIED"]) +- LDFLAGS="$LDFLAGS -Wl,--enable-auto-image-base -Wl,--out-implib,libgnurx.dll.a" +- test -n "${GNURX_LIB}" && LDFLAGS="$LDFLAGS -Wl,--output-def,libgnurx.def" +- AC_CONFIG_FILES([Makefile]) +- AC_OUTPUT +-# +-# $RCSfile: configure.ac,v $Revision: 1.2 $: end of file diff --git a/sdk/recipes/patches/libgnurx/makefile.am.p b/sdk/recipes/patches/libgnurx/makefile.am.p new file mode 100644 index 0000000..cda636d --- /dev/null +++ b/sdk/recipes/patches/libgnurx/makefile.am.p @@ -0,0 +1,11 @@ +--- Makefile.am.orig 1970-01-01 01:00:00.000000000 +0100 ++++ Makefile.am 2015-04-26 13:56:54.997424989 +0100 +@@ -0,0 +1,8 @@ ++lib_LTLIBRARIES = libgnurx.la ++ ++libgnurx_la_SOURCES = regex.c ++libgnurx_la_includedir = $(includedir) ++libgnurx_la_include_HEADERS = regex.h ++libgnurx_la_CFLAGS = -I$(top_srcdir) ++libgnurx_la_LDFLAGS = -no-undefined -version-info 0:0:0 -export-dynamic ++ diff --git a/sdk/recipes/patches/libgnurx/news.p b/sdk/recipes/patches/libgnurx/news.p new file mode 100644 index 0000000..7634852 --- /dev/null +++ b/sdk/recipes/patches/libgnurx/news.p @@ -0,0 +1,4 @@ +--- oNEWS 1970-01-01 01:00:00.000000000 +0100 ++++ NEWS 2015-04-26 13:57:53.963072565 +0100 +@@ -0,0 +1 @@ ++empty -- cgit v1.2.3