summaryrefslogtreecommitdiff
path: root/meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch')
-rw-r--r--meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch32
1 files changed, 13 insertions, 19 deletions
diff --git a/meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch b/meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch
index 37c5c3dc02..2529d5d9d1 100644
--- a/meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch
+++ b/meta-openembedded/meta-oe/recipes-support/libstemmer/libstemmer/0001-Build-so-lib.patch
@@ -8,7 +8,7 @@ Content-Transfer-Encoding: 8bit
Stolen from [1]
-[1] https://aur.archlinux.org/cgit/aur.git/commit/dynamiclib.patch?h=snowball-git&id=a9cbf4f42f3661e4b8f791cd4374233821716ea1
+[1] https://raw.githubusercontent.com/archlinux/svntogit-packages/packages/snowball/trunk/dynamiclib.diff
Upstream-Status: Pending
@@ -19,36 +19,33 @@ Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
2 files changed, 11 insertions(+), 2 deletions(-)
create mode 100644 libstemmer/symbol.map
-diff --git a/GNUmakefile b/GNUmakefile
-index cbd6ff7..a85230b 100644
--- a/GNUmakefile
+++ b/GNUmakefile
-@@ -162,10 +162,10 @@ C_OTHER_OBJECTS = $(C_OTHER_SOURCES:.c=.o)
+@@ -170,12 +170,12 @@ C_OTHER_OBJECTS = $(C_OTHER_SOURCES:.c=.
JAVA_CLASSES = $(JAVA_SOURCES:.java=.class)
JAVA_RUNTIME_CLASSES=$(JAVARUNTIME_SOURCES:.java=.class)
-CFLAGS=-O2 -W -Wall -Wmissing-prototypes -Wmissing-declarations
+CFLAGS=-O2 -fPIC -W -Wall -Wmissing-prototypes -Wmissing-declarations
- CPPFLAGS=-Iinclude
+ CPPFLAGS=
--all: snowball libstemmer.o stemwords $(C_OTHER_SOURCES) $(C_OTHER_HEADERS) $(C_OTHER_OBJECTS)
-+all: snowball libstemmer.o libstemmer.so stemwords $(C_OTHER_SOURCES) $(C_OTHER_HEADERS) $(C_OTHER_OBJECTS)
+ INCLUDES=-Iinclude
- clean:
- rm -f $(COMPILER_OBJECTS) $(RUNTIME_OBJECTS) \
-@@ -212,6 +212,9 @@ libstemmer/libstemmer.o: libstemmer/modules.h $(C_LIB_HEADERS)
- libstemmer.o: libstemmer/libstemmer.o $(RUNTIME_OBJECTS) $(C_LIB_OBJECTS)
+-all: snowball$(EXEEXT) libstemmer.a stemwords$(EXEEXT) $(C_OTHER_SOURCES) $(C_OTHER_HEADERS) $(C_OTHER_OBJECTS)
++all: snowball$(EXEEXT) libstemmer.a libstemmer.so stemwords$(EXEEXT) $(C_OTHER_SOURCES) $(C_OTHER_HEADERS) $(C_OTHER_OBJECTS)
+
+ algorithms.mk: libstemmer/mkalgorithms.pl libstemmer/modules.txt
+ libstemmer/mkalgorithms.pl algorithms.mk libstemmer/modules.txt
+@@ -225,6 +225,9 @@ libstemmer/libstemmer.o: libstemmer/modu
+ libstemmer.a: libstemmer/libstemmer.o $(RUNTIME_OBJECTS) $(C_LIB_OBJECTS)
$(AR) -cru $@ $^
+libstemmer.so: libstemmer/libstemmer.o $(RUNTIME_OBJECTS) $(C_LIB_OBJECTS)
+ $(CC) $(CFLAGS) -shared $(LDFLAGS) -Wl,-soname,libstemmer.so.0,-version-script,libstemmer/symbol.map -o $@.0.0.0 $^
+
- stemwords: $(STEMWORDS_OBJECTS) libstemmer.o
- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
+ examples/%.o: examples/%.c
+ $(CC) $(CFLAGS) $(INCLUDES) $(CPPFLAGS) -c -o $@ $<
-diff --git a/libstemmer/symbol.map b/libstemmer/symbol.map
-new file mode 100644
-index 0000000..7a3d423
--- /dev/null
+++ b/libstemmer/symbol.map
@@ -0,0 +1,6 @@
@@ -58,6 +55,3 @@ index 0000000..7a3d423
+ local:
+ *;
+};
---
-2.20.1
-