summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2021-05-04 11:11:58 -0700
committerJoshua Watt <JPEWhacker@gmail.com>2021-05-04 13:17:12 -0500
commitb05b90c9d9710e64f18711662ec3f011a55c401d (patch)
tree49641d82f5320bcd7d5696ba5f1a7c01a6308027
parent24a5b74daf327fef16a75481eff4bacae0ac6e0d (diff)
downloadmeta-mingw-b05b90c9d9710e64f18711662ec3f011a55c401d.tar.gz
mingw-libgnurx: Add recipe
This implements glibc regex and will be used by many packages e.g. flex, therefore add recipe Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
-rw-r--r--recipes-support/mingw-libgnurx/mingw-libgnurx/0001-Honor-DESTDIR-variable-during-install.patch39
-rw-r--r--recipes-support/mingw-libgnurx/mingw-libgnurx/0002-Add-autotool-files.patch125
-rw-r--r--recipes-support/mingw-libgnurx/mingw-libgnurx_2.5.1.bb17
3 files changed, 181 insertions, 0 deletions
diff --git a/recipes-support/mingw-libgnurx/mingw-libgnurx/0001-Honor-DESTDIR-variable-during-install.patch b/recipes-support/mingw-libgnurx/mingw-libgnurx/0001-Honor-DESTDIR-variable-during-install.patch
new file mode 100644
index 0000000..ea8d9ed
--- /dev/null
+++ b/recipes-support/mingw-libgnurx/mingw-libgnurx/0001-Honor-DESTDIR-variable-during-install.patch
@@ -0,0 +1,39 @@
1From a9b7e07a8ba9c390d9774daae769748a09d409ce Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sat, 1 May 2021 14:41:21 -0700
4Subject: [PATCH] Honor DESTDIR variable during install
5
6Upstream-Status: Pending
7Signed-off-by: Khem Raj <raj.khem@gmail.com>
8---
9 Makefile.in | 14 +++++++-------
10 1 file changed, 7 insertions(+), 7 deletions(-)
11
12diff --git a/Makefile.in b/Makefile.in
13index 6397bf1..8395d2f 100644
14--- a/Makefile.in
15+++ b/Makefile.in
16@@ -78,16 +78,16 @@ gnurx.lib: libgnurx-$(DLLVERSION).dll
17 install: install-dll @install_dev@
18
19 install-dll:
20- mkdir -p ${bindir}
21- cp -p $(BINDIST_FILES) ${bindir}
22+ mkdir -p $(DESTDIR)${bindir}
23+ cp -p $(BINDIST_FILES) $(DESTDIR)${bindir}
24
25 install-dev:
26- mkdir -p ${includedir} ${libdir}
27- cp -p ${srcdir}/regex.h ${includedir}
28- cp -p $(DEVDIST_FILES) ${libdir}
29+ mkdir -p ${includedir} $(DESTDIR)${libdir}
30+ cp -p ${srcdir}/regex.h $(DESTDIR)${includedir}
31+ cp -p $(DEVDIST_FILES) $(DESTDIR)${libdir}
32 for s in 3 7; do \
33- mkdir -p ${mandir}/man$$s; \
34- gzip -c ${srcdir}/regex.$$s > ${mandir}/man$$s/regex.$$s.gz; \
35+ mkdir -p $(DESTDIR)${mandir}/man$$s; \
36+ gzip -c ${srcdir}/regex.$$s > $(DESTDIR)${mandir}/man$$s/regex.$$s.gz; \
37 done
38
39 dist: bindist devdist srcdist
diff --git a/recipes-support/mingw-libgnurx/mingw-libgnurx/0002-Add-autotool-files.patch b/recipes-support/mingw-libgnurx/mingw-libgnurx/0002-Add-autotool-files.patch
new file mode 100644
index 0000000..1365f24
--- /dev/null
+++ b/recipes-support/mingw-libgnurx/mingw-libgnurx/0002-Add-autotool-files.patch
@@ -0,0 +1,125 @@
1From 0b74bbc32c4acf5b67d7568a5d1e776fe6578202 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Sat, 1 May 2021 14:53:09 -0700
4Subject: [PATCH] Add autotool files
5
6This helps in reconfiguring the component with autotools on Linux
7
8Upstream-Status: Pending
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10---
11 Makefile.am | 7 ++++
12 configure.ac | 90 ++++++----------------------------------------------
13 2 files changed, 16 insertions(+), 81 deletions(-)
14 create mode 100644 Makefile.am
15
16diff --git a/Makefile.am b/Makefile.am
17new file mode 100644
18index 0000000..be0a797
19--- /dev/null
20+++ b/Makefile.am
21@@ -0,0 +1,7 @@
22+lib_LTLIBRARIES = libgnurx.la
23+
24+libgnurx_la_SOURCES = regex.c
25+libgnurx_la_includedir = $(includedir)
26+libgnurx_la_include_HEADERS = regex.h
27+libgnurx_la_CFLAGS = -I$(top_srcdir)
28+libgnurx_la_LDFLAGS = -no-undefined -version-info 0:0:0 -export-dynamic
29diff --git a/configure.ac b/configure.ac
30index c97738d..de64f75 100644
31--- a/configure.ac
32+++ b/configure.ac
33@@ -1,83 +1,11 @@
34 # configure.ac -*- Autoconf -*-
35 # Process this file with autoconf, to generate a configure script.
36-#
37-# $Id: configure.ac,v 1.2 2007/05/03 22:46:09 keithmarshall Exp $
38-#
39-# Copyright (C) 2007, MinGW Project
40-# Written by Keith Marshall <keithmarshall@users.sourceforge.net>
41-#
42-# Package identification.
43-#
44-# This is configure.ac for the MinGW `libgnurx' package.
45-# BASENAME, VERSION_MAJOR and VERSION_MINOR are required tags;
46-# complete `Value' fields as appropriate.
47-#
48-# Tag Value
49-# --------------- ----------
50- MINGW_AC_DEFINE_PACKAGE_ID([BASENAME], [libgnurx])
51- MINGW_AC_DEFINE_PACKAGE_ID([VERSION_MAJOR], [2])
52- MINGW_AC_DEFINE_PACKAGE_ID([VERSION_MINOR], [5])
53-#
54-# PATCHLEVEL is optional; comment/uncomment and adjust as required.
55-#
56- MINGW_AC_DEFINE_PACKAGE_ID([PATCHLEVEL], [1])
57-#
58-# DLL_VERSION is required; installed DLLs will be versioned, by
59-# appending a hyphen, the specified tag value, and then the `.dll'
60-# file name extension, to the base name of each generated DLL.
61-#
62- MINGW_AC_DEFINE_PACKAGE_ID([DLL_VERSION], [0])
63-#
64-#
65-# libgnurx is an adaptation of Tor Lillqvist's original port of the
66-# regex functions from GNU libc, for use on native Woe32 platforms.
67-#
68-# The original sources, on which this port is based, remain copyright
69-# of their respective authors, or of the Free Software Foundation Inc.,
70-# as indicated in individual file headers; all are redistributed with
71-# permission, as granted by the GNU Lesser General Public License.
72-#
73-# This is free software. It is provided AS IS, in the hope that it may
74-# be useful, but WITHOUT WARRANTY OF ANY KIND, not even an IMPLIED WARRANTY
75-# of MERCHANTABILITY, nor of FITNESS FOR ANY PARTICULAR PURPOSE.
76-#
77-# Permission is granted to redistribute this software, either "as is" or
78-# in modified form, under the terms of the GNU Lesser General Public License,
79-# as published by the Free Software Foundation; either version 2.1, or (at
80-# your option) any later version.
81-#
82-# You should have received a copy of the GNU Lesser General Public License
83-# along with this software; see the file COPYING.LIB. If not, write to the
84-# Free Software Foundation, 51 Franklin St - Fifth Floor, Boston,
85-# MA 02110-1301, USA.
86-
87-# Autoconf initialisation.
88-#
89- AC_PREREQ([2.59])
90- AC_INIT(__MINGW_AC_PACKAGE_IDENTIFICATION__)
91-
92-# Compiler and build tool checks.
93-#
94- AC_PROG_CC
95- MINGW_AC_PROG_CC_OPTIONS([CC_QUALIFIED], [-m], [threads tune=pentium3])
96-
97-# Set the release version for the resultant DLL.
98-#
99- AC_SUBST([DLLVERSION], [__MINGW_AC_PACKAGE_DLL_VERSION__])
100-
101-# User configuration options.
102-#
103- MINGW_AC_DISTRIBUTION_TYPE([tar])
104- MINGW_AC_MSVC_IMPORT_LIBS([GNURX_LIB], [gnurx.lib])
105- MINGW_AC_DEV_INSTALL_OPTION
106-
107-# Configuration output.
108-#
109- AC_SUBST([GNURX_LIB])
110- AC_SUBST([CC_QUALIFIED], ["$CC $CC_QUALIFIED"])
111- LDFLAGS="$LDFLAGS -Wl,--enable-auto-image-base -Wl,--out-implib,libgnurx.dll.a"
112- test -n "${GNURX_LIB}" && LDFLAGS="$LDFLAGS -Wl,--output-def,libgnurx.def"
113- AC_CONFIG_FILES([Makefile])
114- AC_OUTPUT
115-#
116-# $RCSfile: configure.ac,v $Revision: 1.2 $: end of file
117+
118+AC_INIT(libgnurx, 2.5.1)
119+AM_INIT_AUTOMAKE(foreign)
120+AC_PROG_INSTALL
121+AC_LIBTOOL_DLOPEN
122+AC_LIBTOOL_WIN32_DLL
123+AC_PROG_LIBTOOL
124+
125+AC_OUTPUT([Makefile])
diff --git a/recipes-support/mingw-libgnurx/mingw-libgnurx_2.5.1.bb b/recipes-support/mingw-libgnurx/mingw-libgnurx_2.5.1.bb
new file mode 100644
index 0000000..ca5bbf9
--- /dev/null
+++ b/recipes-support/mingw-libgnurx/mingw-libgnurx_2.5.1.bb
@@ -0,0 +1,17 @@
1# Copyright (C) 2021 Khem Raj <raj.khem@gmail.com>
2# Released under the MIT license (see COPYING.MIT for the terms)
3LICENSE = "LGPLv2.1"
4LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=bbb461211a33b134d42ed5ee802b37ff"
5
6SRC_URI = "http://download.sourceforge.net/mingw/Other/UserContributed/regex/mingw-regex-${PV}/mingw-libgnurx-${PV}-src.tar.gz \
7 file://0001-Honor-DESTDIR-variable-during-install.patch \
8 file://0002-Add-autotool-files.patch \
9 "
10SRC_URI[sha256sum] = "7147b7f806ec3d007843b38e19f42a5b7c65894a57ffc297a76b0dcd5f675d76"
11
12inherit autotools
13
14# Specify any options you want to pass to the configure script using EXTRA_OECONF:
15EXTRA_OECONF = ""
16
17BBCLASSEXTEND = "nativesdk"