recipes: Rename 'pkghashtag' variable to 'pkgcategory'
[dragora.git] / recipes / devel / nasm / recipe
blobe7c96aa7f09ffb199fdf9bb9f4df772ac15c75f8
1 # Build recipe for NASM.
3 # Copyright (C) 2018, MMPG <mmpg@vp.pl>
4 # Copyright (c) 2018 Matias Fonzo, <selk@dragora.org>.
6 # Licensed under the Apache License, Version 2.0 (the "License");
7 # you may not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
10 #    http://www.apache.org/licenses/LICENSE-2.0
12 # Unless required by applicable law or agreed to in writing, software
13 # distributed under the License is distributed on an "AS IS" BASIS,
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 # See the License for the specific language governing permissions and
16 # limitations under the License.
18 program=nasm
19 version=2.14.02
20 release=1
22 # Define a category for the output of the package name
23 pkgcategory=devel
25 tarname=${program}-${version}.tar.bz2
27 # Remote source(s)
28 fetch=http://www.nasm.us/pub/nasm/releasebuilds/$version/$tarname
30 description="
31 A free portable assembler.
33 Designed for the Intel 80x86 microprocessor series,
34 using primarily the traditional Intel instruction mnemonics and syntax.
37 homepage=http://nasm.us
38 license=BSD
40 docs="AUTHORS CHANGES ChangeLog LICENSE README TODO"
41 docsdir="${docdir}/${program}-${version}"
43 build()
45     set -e
47     unpack "${tardir}/$tarname"
49     cd "$srcdir"
51     # Set sane permissions
52     chmod -R u+w,go-w,a+rX-s .
54     ./configure CFLAGS="$QICFLAGS" LDFLAGS="$QILDFLAGS" \
55      $configure_args \
56      --mandir=$mandir \
57      --docdir=$docsdir \
58      --disable-pdf-compression \
59      --enable-sections \
60      --build="$(cc -dumpmachine)"
62     make -j${jobs} V=1
63     make -j${jobs} DESTDIR="$destdir" install install_rdf
65     # Compress manpages
66     lzip -9 "${destdir}/${mandir}/"man1/*.1
68     # Copy documentation
69     mkdir -p "${destdir}${docsdir}"
70     cp -p $docs "${destdir}${docsdir}"