aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.in4
-rw-r--r--nasm.spec.in (renamed from nasm.spec)23
2 files changed, 17 insertions, 10 deletions
diff --git a/Makefile.in b/Makefile.in
index e21b392a..818809ef 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -132,6 +132,7 @@ distclean: clean
cleaner: clean
rm -f insnsa.c insnsd.c insnsi.h insnsn.c macros.c *.man
+ rm -f nasm.spec
cd doc && $(MAKE) clean
spotless: distclean cleaner
@@ -159,3 +160,6 @@ dist: spotless perlreq
autoconf
rm -rf ./autom4te.cache
tar cvjf ../nasm-`cat version`-`date +%Y%m%d`.tar.bz2 ../`./nasm-dir`
+
+nasm.spec: nasm.spec.in version
+ sed -e s/@@VERSION@@/`cat version`/g < nasm.spec.in > nasm.spec
diff --git a/nasm.spec b/nasm.spec.in
index c5475134..b6652e1e 100644
--- a/nasm.spec
+++ b/nasm.spec.in
@@ -1,13 +1,15 @@
Summary: The Netwide Assembler, a portable x86 assembler with Intel-like syntax
Name: nasm
-Version: 0.98
+Version: @@VERSION@@
Release: 1
-Copyright: Freely Distributable
+Copyright: LGPL
Group: Development/Languages
-Source: ftp://ftp.us.kernel.org/pub/software/devel/nasm/source/nasm-%{version}.tar.gz
-URL: http://www.cryogen.com/Nasm/
+Source: ftp://download.sourceforge.net/pub/sourceforge/nasm/nasm-%{version}.tar.bz2
+URL: http://nasm.2y.net/
BuildRoot: /tmp/rpm-build-nasm
Prefix: /usr
+Patch0: nasm-0.98.25alt-nasmopt.diff
+BuildPrereq: perl
%package doc
Summary: Extensive documentation for NASM
@@ -34,26 +36,28 @@ include linker, library manager, loader, and information dump.
%prep
%setup
+%patch0 -p1
%build
CFLAGS="$RPM_OPT_FLAGS" LDFLAGS=-s ./configure --prefix=/usr
make everything
%install
+rm -rf "$RPM_BUILD_ROOT"
mkdir -p "$RPM_BUILD_ROOT"
mkdir -p "$RPM_BUILD_ROOT"/usr/bin
mkdir -p "$RPM_BUILD_ROOT"/usr/man/man1
mkdir -p "$RPM_BUILD_ROOT"/usr/info
DOC="$RPM_BUILD_ROOT"/usr/doc/nasm-%{version}
-rm -rf "$DOC"
mkdir -p "$DOC"
mkdir -p "$DOC"/rdoff
rm -f "$RPM_BUILD_ROOT"/usr/info/nasm.*
make INSTALLROOT="$RPM_BUILD_ROOT" docdir=/usr/doc/nasm-%{version} install_everything
gzip -9 "$RPM_BUILD_ROOT"/usr/info/nasm.*
gzip -9 "$DOC"/*.txt "$DOC"/*.ps
-cp Changes Licence MODIFIED Readme Wishlist *.doc changed.asm "$DOC"
-cp rdoff/README rdoff/Changes "$DOC"/rdoff
+cp AUTHORS CHANGES COPYING README TODO doc/*.doc "$DOC"
+cp rdoff/README "$DOC"/rdoff
+cp rdoff/doc/* "$DOC"/rdoff
%clean
rm -rf "$RPM_BUILD_ROOT"
@@ -69,9 +73,8 @@ fi
%files
%attr(-,root,root) /usr/bin/nasm
%attr(-,root,root) /usr/bin/ndisasm
-%attr(-,root,root) %doc /usr/man/man1/nasm.1
-%attr(-,root,root) %doc /usr/man/man1/ndisasm.1
-%attr(-,root,root) %doc /usr/doc/nasm-%{version}/Licence
+%attr(-,root,root) %doc /usr/man/man1/nasm.1*
+%attr(-,root,root) %doc /usr/man/man1/ndisasm.1*
%files doc
%attr(-,root,root) %doc /usr/info/nasm.info*.gz