summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElan Ruusamäe2009-11-21 12:38:31 (GMT)
committercvs2git2012-06-24 12:13:13 (GMT)
commit42de7bdc8a0e4e51129b80f040c94c331eda210d (patch)
tree88e6ec446817fd0353a81836e8a11b6d8a952448
parente8cc17cfe42fdb3107048f0fa4556050ce073793 (diff)
downloadlibstemmer-AC-branch.zip
libstemmer-AC-branch.tar.gz
- add libtool --tag, optflags. patchesauto/ac/libstemmer-20090915-1AC-branch
Changed files: libstemmer.spec -> 1.4 libtool-tag.patch -> 1.1 optflags.patch -> 1.1
-rw-r--r--libstemmer.spec8
-rw-r--r--libtool-tag.patch33
-rw-r--r--optflags.patch10
3 files changed, 49 insertions, 2 deletions
diff --git a/libstemmer.spec b/libstemmer.spec
index e820f4e..824855f 100644
--- a/libstemmer.spec
+++ b/libstemmer.spec
@@ -7,6 +7,8 @@ Group: Libraries
Source0: http://snowball.tartarus.org/dist/%{name}_c.tgz
# Source0-md5: 530e491060442013e2c39d34275e4bfd
Patch0: %{name}-makefile.patch
+Patch1: libtool-tag.patch
+Patch2: optflags.patch
URL: http://snowball.tartarus.org/
BuildRequires: libtool
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -57,11 +59,13 @@ Narzędzie stemwords korzystające z biblioteki libstemmer.
%prep
%setup -q -n %{name}_c
%patch0 -p0
+%patch1 -p1
+%patch2 -p1
%build
%{__make} \
- CFLAGS="%{rpmcflags} -Iinclude -fPIC" \
- CC="%{__cc}"
+ CC="%{__cc}" \
+ OPTFLAGS="%{rpmcflags}"
%install
rm -rf $RPM_BUILD_ROOT
diff --git a/libtool-tag.patch b/libtool-tag.patch
new file mode 100644
index 0000000..b43cb6a
--- /dev/null
+++ b/libtool-tag.patch
@@ -0,0 +1,33 @@
+--- libstemmer_c/Makefile~ 2009-11-21 14:34:37.000000000 +0200
++++ libstemmer_c/Makefile 2009-11-21 14:35:39.761787074 +0200
+@@ -21,25 +21,25 @@
+ all: libstemmer.la stemwords
+
+ libstemmer.la: $(LTOBJS)
+- $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -rpath $(libdir) \
++ $(LIBTOOL) --tag=CC --mode=link $(CC) $(CFLAGS) -rpath $(libdir) \
+ -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) -o \
+ $@ $(LTOBJS)
+
+ stemwords: examples/stemwords.o libstemmer.la
+- $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -o $@ $(LDFLAGS) $^
++ $(LIBTOOL) --tag=CC --mode=link $(CC) $(CFLAGS) -o $@ $(LDFLAGS) $^
+
+ %.o: %.c
+ $(CC) -c $(CFLAGS) $< -o $@
+
+ %.lo: %.c
+- $(LIBTOOL) --mode=compile $(CC) -c $(CFLAGS) $< -o $@
++ $(LIBTOOL) --tag=CC --mode=compile $(CC) -c $(CFLAGS) $< -o $@
+
+ install:
+ $(INSTALL) -d $(DESTDIR)$(bindir)
+ $(INSTALL) -d $(DESTDIR)$(libdir)
+ $(INSTALL) -d $(DESTDIR)$(includedir)/libstemmer
+- $(LIBTOOL) --mode=install $(INSTALL) libstemmer.la $(DESTDIR)$(libdir)
+- $(LIBTOOL) --mode=install $(INSTALL) -m 755 stemwords $(DESTDIR)$(bindir)
++ $(LIBTOOL) --tag=CC --mode=install $(INSTALL) libstemmer.la $(DESTDIR)$(libdir)
++ $(LIBTOOL) --tag=CC --mode=install $(INSTALL) -m 755 stemwords $(DESTDIR)$(bindir)
+ $(INSTALL) -m 644 libstemmer/modules.h $(DESTDIR)$(includedir)/libstemmer
+ $(INSTALL) -m 644 runtime/api.h $(DESTDIR)$(includedir)/libstemmer
+ $(INSTALL) -m 644 runtime/header.h $(DESTDIR)$(includedir)/libstemmer
diff --git a/optflags.patch b/optflags.patch
new file mode 100644
index 0000000..02a88b0
--- /dev/null
+++ b/optflags.patch
@@ -0,0 +1,10 @@
+--- libstemmer_c/Makefile~ 2009-11-21 14:36:24.000000000 +0200
++++ libstemmer_c/Makefile 2009-11-21 14:37:22.059947733 +0200
+@@ -1,5 +1,6 @@
+ include mkinc.mak
+-CFLAGS+=-Wall -Iinclude -fPIC -DPIC -D_REENTRANT
++OPTFLAGS = -Wall
++CFLAGS+= $(OPTFLAGS) -Iinclude -fPIC -DPIC -D_REENTRANT
+ CC=gcc
+ bindir = /usr/bin
+ libdir = /usr/lib