[pure] Update to 0.47

Michel Alexandre Salim salimma at fedoraproject.org
Mon Apr 4 23:53:24 UTC 2011


commit 35a0335fcfd5d5e783c62a48cbdf4f0bbf250d02
Author: Michel Alexandre Salim <michel at sylvestre.me>
Date:   Tue Apr 5 01:53:13 2011 +0200

    Update to 0.47

 .gitignore                         |    3 +-
 pure-0.45-custom_llvm_libdir.patch |   11 -------
 pure-0.47-pc_mode.patch            |   11 +++++++
 pure.spec                          |   56 ++++++++++++++++++++----------------
 sources                            |    3 +-
 5 files changed, 46 insertions(+), 38 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e624210..ad1480b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
-/pure-0.45.tar.gz
+/pure-0.47.tar.gz
+/pure-docs-0.47.tar.gz
diff --git a/pure-0.47-pc_mode.patch b/pure-0.47-pc_mode.patch
new file mode 100644
index 0000000..fcbe1bc
--- /dev/null
+++ b/pure-0.47-pc_mode.patch
@@ -0,0 +1,11 @@
+--- pure-0.47/Makefile.in.pc_mode	2011-03-31 20:15:12.000000000 +0200
++++ pure-0.47/Makefile.in	2011-04-05 01:04:20.836024751 +0200
+@@ -323,7 +323,7 @@
+ endif
+ endif
+ 	$(INSTALL) pure$(EXE) $(DESTDIR)$(bindir)/$(pure_exe)
+-	$(INSTALL) pure.pc $(DESTDIR)$(pkgconfigdir)/$(pure_pc)
++	$(INSTALL) -m 644 pure.pc $(DESTDIR)$(pkgconfigdir)/$(pure_pc)
+ 	$(INSTALL) -m 644 $(srcdir)/runtime.h $(DESTDIR)$(pure_includedir)
+ 	$(INSTALL) -m 644 $(srcdir)/pure_main.c pure_main.o $(DESTDIR)$(pure_libdir)
+ 	for x in $(srcdir)/lib/*.pure; do $(INSTALL) -m 644 $$x $(DESTDIR)$(pure_libdir); done
diff --git a/pure.spec b/pure.spec
index ff9cb91..d0388b4 100644
--- a/pure.spec
+++ b/pure.spec
@@ -1,20 +1,20 @@
 Name:           pure
-Version:        0.45
-Release:        4%{?dist}
+Version:        0.47
+Release:        1%{?dist}
 Summary:        A term-rewriting functional programming language
 
 Group:          Development/Languages
-License:        LGPLv3+
+License:        LGPLv3+ with exceptions
 URL:            http://code.google.com/p/pure-lang/
 Source0:        http://pure-lang.googlecode.com/files/pure-%{version}.tar.gz
-Source1:        pure-init.el
-# improve pure's detection of LLVM shared library
-# http://code.google.com/p/pure-lang/issues/detail?id=47
-Patch0:         pure-0.45-custom_llvm_libdir.patch
+Source1:	http://pure-lang.googlecode.com/files/pure-docs-%{version}.tar.gz
+Source2:        pure-init.el
+Patch0:         pure-0.47-pc_mode.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  gmp-devel libedit-devel
 BuildRequires:  llvm-devel >= 2.4 flex bison
+BuildRequires:  clang
 # For compiling emacs mode
 BuildRequires:  emacs emacs-el
 # For integrated help in the interpreter
@@ -28,7 +28,7 @@ Pure is a modern-style functional programming language based on term
 rewriting. It offers equational definitions with pattern matching,
 full symbolic rewriting capabilities, dynamic typing, eager and lazy
 evaluation, lexical closures, built-in list and matrix support and an
-easy-to-use C interface. The interpreter uses LLVM as a backend to
+easy-to-use C interface. The interpreter uses LLVM as a back-end to
 JIT-compile Pure programs to fast native code.
 
 
@@ -75,40 +75,40 @@ This package contains the elisp source file for the Pure mode for Emacs.
 
 %prep
 %setup -q
-%patch0 -p1 -b .custom_llvm_libdir
+cp -p %{SOURCE1} .
+%patch0 -p1 -b .pc_mode
 
 
 %build
+# TODO
+#export CC=clang
+#export CXX=clang++
 %ifarch ppc
 # http://code.google.com/p/pure-lang/issues/detail?id=13#c47
-%configure --disable-fastcc
+%configure --enable-release --disable-fastcc
 %else
-%configure
+%configure --enable-release
 %endif
 
 make %{?_smp_mflags}
-# Compile emacs module
-cd etc && emacs -batch -f batch-byte-compile pure-mode.el
 
 
 %install
 rm -rf $RPM_BUILD_ROOT
 make install DESTDIR=$RPM_BUILD_ROOT
+# trick the docs installation to go to %{_datadir} so it can be
+# shared among different arches
+make install-docs DESTDIR=$RPM_BUILD_ROOT \
+     libdir=%{_datadir} docs=%{name}-docs-%{version}.tar.gz
+(cd $RPM_BUILD_ROOT%{_libdir}/pure && ln -s %{_datadir}/pure/docs .)
 
-# Emacs mode files
-rm etc/*.el.in
-mkdir -p $RPM_BUILD_ROOT%{_emacs_sitelispdir}
+# Emacs init file
 mkdir -p $RPM_BUILD_ROOT%{_emacs_sitestartdir}
-mv etc/*.el* $RPM_BUILD_ROOT%{_emacs_sitelispdir}
-cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_emacs_sitestartdir}
+cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_emacs_sitestartdir}
 
 
 %check
-%ifnarch ppc
 make check
-%else
-(make check 2>&1 | tee testlog.txt ; true)
-%endif
 
 
 %clean
@@ -124,13 +124,14 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(-,root,root,-)
 %doc ChangeLog COPYING* NEWS README TODO etc
-%ifarch ppc
-%doc testlog.txt test/test020.*
-%endif
 %{_bindir}/pure*
 %{_libdir}/libpure*.so.*
 %exclude %{_libdir}/pure/pure_main.c
 %{_libdir}/pure*
+# own these to avoid dangling symlinks
+# in case -doc is not installed
+%dir %{_datadir}/pure
+%dir %{_datadir}/pure/docs
 %{_mandir}/man1/*
 
 %files devel
@@ -138,10 +139,12 @@ rm -rf $RPM_BUILD_ROOT
 %{_includedir}/pure*
 %{_libdir}/*.so
 %{_libdir}/pure/pure_main.c
+%{_libdir}/pkgconfig/pure.pc
 
 %files doc
 %defattr(-,root,root,-)
 %doc examples
+%doc %{_datadir}/pure/docs/*
 
 %files -n emacs-pure
 %defattr(-,root,root,-)
@@ -155,6 +158,9 @@ rm -rf $RPM_BUILD_ROOT
 
 
 %changelog
+* Tue Apr  5 2011 Michel Salim <salimma at fedoraproject.org> - 0.47-1
+- Update to 0.47
+
 * Wed Feb 09 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 0.45-4
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
 
diff --git a/sources b/sources
index afa1eec..e70ac7e 100644
--- a/sources
+++ b/sources
@@ -1 +1,2 @@
-c7c6debbbde6acc1fb7bd20e222d03bb  pure-0.45.tar.gz
+0b3745be6151c2d77150bd4678b4534d  pure-0.47.tar.gz
+fcf37e92ede02e99704a824906665aa2  pure-docs-0.47.tar.gz


More information about the scm-commits mailing list