Magellan Linux

Annotation of /smage/trunk/core/flex/flex-2.5.35-r3.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 951 - (hide annotations) (download)
Fri Dec 10 17:42:22 2010 UTC (13 years, 5 months ago) by niro
File size: 1193 byte(s)
auto added: ver bump to 2.5.35-r3
1 niro 951 # $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="r3"
6    
7     PCATEGORIE="sys-dev"
8     STATE="unstable"
9    
10     DESCRIPTION="GNU fast lexical analyser generator."
11     HOMEPAGE="http://flex.sourceforge.net/"
12    
13     DEPEND=">= virtual/glibc"
14     SDEPEND=">= sys-dev/bison-2"
15    
16     SRCFILE="${PNAME}-${PVER}.tar.bz2"
17     SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
18    
19     sminclude gnuconfig mtools multilib
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     # add updated config.{sub,guess} for xxx-pc-linux-uclibc target
33     all-abis gnuconfig-update '${SRCDIR}-${abi}' || die
34    
35     # do not regenerate the man page
36     all-abis touch '${SRCDIR}-${abi}'/doc/flex.1 || die
37     }
38    
39     src_compile()
40     {
41     mconfigure || die
42    
43     # flex doesn't compiles sometimes with > -j1
44     mmake -j1 || die
45     }
46    
47     src_install()
48     {
49     # needed directory
50     minstalldir /usr/share/man/man1 || die
51    
52     minstall_destdir || die
53    
54     all-abis mlink libfl.a /usr/'$(mlibdir)'/libl.a || die
55    
56     cat > ${BINDIR}/usr/bin/lex << "EOF"
57     #!/bin/sh
58     exec /usr/bin/flex -l "$@"
59     EOF
60    
61     mchmod 755 /usr/bin/lex || die
62     }