packages: hfst-morph-sv/hfst-morph-sv-DESTDIR.patch (NEW), hfst-morph-sv/hf...

qboosh qboosh at pld-linux.org
Sun Jun 12 22:32:28 CEST 2011


Author: qboosh                       Date: Sun Jun 12 20:32:28 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- new

---- Files affected:
packages/hfst-morph-sv:
   hfst-morph-sv-DESTDIR.patch (NONE -> 1.1)  (NEW), hfst-morph-sv.spec (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: packages/hfst-morph-sv/hfst-morph-sv-DESTDIR.patch
diff -u /dev/null packages/hfst-morph-sv/hfst-morph-sv-DESTDIR.patch:1.1
--- /dev/null	Sun Jun 12 22:32:28 2011
+++ packages/hfst-morph-sv/hfst-morph-sv-DESTDIR.patch	Sun Jun 12 22:32:23 2011
@@ -0,0 +1,42 @@
+--- hfst-english-installable/Makefile.orig	2011-04-27 16:20:32.000000000 +0200
++++ hfst-english-installable/Makefile	2011-05-29 07:58:40.920047209 +0200
+@@ -1,6 +1,7 @@
+ langname = english
+ langcode = en
+ 
++DESTDIR =
+ analyzer_transducer = $(langcode)-analysis.hfst.ol
+ generator_transducer = $(langcode)-generation.hfst.ol
+ prefix = /usr/local
+@@ -10,19 +11,19 @@
+ generator_script = $(binarypath)/${langname}-generate.sh
+ 
+ install:
+-	install -m 0775 -d $(transducerpath)
+-	install -m 0664 $(analyzer_transducer) --target-directory=$(transducerpath)
+-	install -m 0664 $(generator_transducer) --target-directory=$(transducerpath)
++	install -m 0775 -d $(DESTDIR)$(transducerpath) $(DESTDIR)$(binarypath)
++	install -m 0664 $(analyzer_transducer) --target-directory=$(DESTDIR)$(transducerpath)
++	install -m 0664 $(generator_transducer) --target-directory=$(DESTDIR)$(transducerpath)
+ 	sed -e s,BINPATH,$(binarypath),g -e s,TRPATH,$(transducerpath),g \
+-		< ${langname}-analyze.sh > $(binarypath)/${langname}-analyze.sh
++		< ${langname}-analyze.sh > $(DESTDIR)$(binarypath)/${langname}-analyze.sh
+ 	sed -e s,BINPATH,$(binarypath),g -e s,TRPATH,$(transducerpath),g \
+-		< ${langname}-generate.sh > $(binarypath)/${langname}-generate.sh
+-	chmod 0755 $(analyzer_script)
+-	chmod 0755 $(generator_script)
++		< ${langname}-generate.sh > $(DESTDIR)$(binarypath)/${langname}-generate.sh
++	chmod 0755 $(DESTDIR)$(analyzer_script)
++	chmod 0755 $(DESTDIR)$(generator_script)
+ 
+ clean:
+-	rm -f $(transducerpath)/$(analyzer_transducer)
+-	rm -f $(transducerpath)/$(generator_transducer)
+-	rmdir --ignore-fail-on-non-empty $(transducerpath)
+-	rm -f $(analyzer_script)
+-	rm -f $(generator_script)
++	rm -f $(DESTDIR)$(transducerpath)/$(analyzer_transducer)
++	rm -f $(DESTDIR)$(transducerpath)/$(generator_transducer)
++	rmdir --ignore-fail-on-non-empty $(DESTDIR)$(transducerpath)
++	rm -f $(DESTDIR)$(analyzer_script)
++	rm -f $(DESTDIR)$(generator_script)

================================================================
Index: packages/hfst-morph-sv/hfst-morph-sv.spec
diff -u /dev/null packages/hfst-morph-sv/hfst-morph-sv.spec:1.1
--- /dev/null	Sun Jun 12 22:32:28 2011
+++ packages/hfst-morph-sv/hfst-morph-sv.spec	Sun Jun 12 22:32:23 2011
@@ -0,0 +1,55 @@
+# $Revision$, $Date$
+Summary:	HFST morphological analysis transducer for Swedish language
+Summary(pl.UTF-8):	Automat HFST do analizy morfologicznej dla języka szwedzkiego
+Name:		hfst-morph-sv
+# or 20110316?
+Version:	0
+Release:	1
+License:	CC-SA v1.0
+Group:		Applications/Text
+# source is hfst-swedish.tar.gz, but it doesn't contain scripts
+Source0:	http://downloads.sourceforge.net/hfst/hfst-swedish-installable.tar.gz
+# Source0-md5:	fac0f40423b416c2d3bbd5ace51f25c3
+Patch0:		%{name}-DESTDIR.patch
+URL:		http://hfst.sourceforge.net/
+Requires:	hfst
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+This is a Swedish Swelex morphological transducer for HFST. It's based
+on "Den stora svenska ordlistan" <http://dsso.se/>.
+
+%description -l pl.UTF-8
+Ten pakiet zawiera automat Swelex dla HFST do analizy morfologicznej
+języka szwedzkiego. Jest oparty na "Den stora svenska ordlistan"
+<http://dsso.se/>.
+
+%prep
+%setup -q -n hfst-swedish-installable
+%patch0 -p1
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} install \
+	DESTDIR=$RPM_BUILD_ROOT \
+	prefix=%{_prefix}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc README
+%attr(755,root,root) %{_bindir}/swedish-analyze.sh
+%attr(755,root,root) %{_bindir}/swedish-generate.sh
+%{_datadir}/hfst/sv
+
+%define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
+%changelog
+* %{date} PLD Team <feedback at pld-linux.org>
+All persons listed below can be reached at <cvs_login>@pld-linux.org
+
+$Log$
+Revision 1.1  2011/06/12 20:32:23  qboosh
+- new
================================================================


More information about the pld-cvs-commit mailing list