Contents of /smage/trunk/core/flex/flex-2.5.35-r1.smage2
Parent Directory | Revision Log
Revision 2792 -
(show annotations)
(download)
Mon Aug 29 20:03:18 2011 UTC (12 years, 9 months ago) by niro
File size: 1084 byte(s)
Mon Aug 29 20:03:18 2011 UTC (12 years, 9 months ago) by niro
File size: 1084 byte(s)
-merged branch alx-0_6_0 into trunk
1 | # $Id: flex-2.5.35-r2.smage2 97 2010-01-06 12:15:41Z niro $ |
2 | |
3 | PNAME="flex" |
4 | PVER="2.5.35" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="sys-dev" |
8 | |
9 | DESCRIPTION="GNU fast lexical analyser generator." |
10 | HOMEPAGE="http://flex.sourceforge.net/" |
11 | |
12 | DEPEND=">= virtual/glibc" |
13 | SDEPEND=">= sys-dev/bison-2" |
14 | |
15 | SRCFILE="${PNAME}-${PVER}.tar.bz2" |
16 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
17 | |
18 | REMOVE_DEPRECATED_MAGE_TARGETS=1 |
19 | sminclude mtools multilib alx |
20 | |
21 | SRC_URI=( |
22 | sourceforge://${PNAME}/${SRCFILE} |
23 | mirror://${PNAME}/${SRCFILE} |
24 | ) |
25 | |
26 | UP2DATE="updatecmd ${HOMEPAGE} | grep version | sed 's/.* version \(.*\) i.*/\1/;q'" |
27 | |
28 | src_prepare() |
29 | { |
30 | munpack ${SRCFILE} || die |
31 | |
32 | # do not regenerate the man page |
33 | all-abis touch '${SRCDIR}-${abi}'/doc/flex.1 || die |
34 | } |
35 | |
36 | src_compile() |
37 | { |
38 | mconfigure || die |
39 | |
40 | # flex doesn't compiles sometimes with > -j1 |
41 | mmake -j1 || die |
42 | } |
43 | |
44 | src_install() |
45 | { |
46 | # needed directory |
47 | minstalldir /usr/share/man/man1 || die |
48 | |
49 | minstall_destdir || die |
50 | |
51 | all-abis mlink libfl.a /usr/'$(mlibdir)'/libl.a || die |
52 | |
53 | cat > ${BINDIR}/usr/bin/lex << "EOF" |
54 | #!/bin/sh |
55 | exec /usr/bin/flex -l "$@" |
56 | EOF |
57 | |
58 | mchmod 755 /usr/bin/lex || die |
59 | } |