Contents of /trunk/core/flex/flex-2.6.4-r2.smage2
Parent Directory | Revision Log
Revision 33372 -
(show annotations)
(download)
Thu Jul 13 15:03:15 2023 UTC (11 months ago) by niro
File size: 1162 byte(s)
Thu Jul 13 15:03:15 2023 UTC (11 months ago) by niro
File size: 1162 byte(s)
-toolchain rebuild
1 | # $Id$ |
2 | |
3 | PNAME="flex" |
4 | PVER="2.6.4" |
5 | PBUILD="r2" |
6 | |
7 | PCAT="sys-dev" |
8 | |
9 | DESCRIPTION="GNU fast lexical analyser generator." |
10 | HOMEPAGE="https://github.com/westes/flex/releases" |
11 | |
12 | DEPEND=">= virtual/glibc |
13 | >= sys-dev/m4-1.4" |
14 | |
15 | SDEPEND=">= sys-dev/bison-3.8" |
16 | |
17 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
18 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
19 | |
20 | # one check fails: cxx_restarts |
21 | msetfeature "!check" |
22 | |
23 | sminclude mtools multilib |
24 | |
25 | SRC_URI=( |
26 | https://github.com/westes/${PNAME}/releases/download/v${PVER}/${SRCFILE} |
27 | mirror://${PNAME}/${SRCFILE} |
28 | ) |
29 | |
30 | UP2DATE="updatecmd -nolist https://github.com/westes/flex/releases | highesttarball gz" |
31 | |
32 | src_prepare() |
33 | { |
34 | munpack ${SRCFILE} || die |
35 | |
36 | # remove tests which are incompatible with the latest bison |
37 | all-abis sed -i -e '/test-bison-yylloc/d' -e '/test-bison-yylval/d' tests/Makefile.in || die |
38 | |
39 | # do not regenerate the man page |
40 | all-abis touch '${SRCDIR}-${abi}'/doc/flex.1 || die |
41 | } |
42 | |
43 | src_compile() |
44 | { |
45 | mconfigure || die |
46 | |
47 | # prevent excessive overlinking due to libtool |
48 | all-abis "sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool || die" |
49 | |
50 | mmake || die |
51 | } |
52 | |
53 | src_install() |
54 | { |
55 | mmake DESTDIR=${BINDIR} install || die |
56 | mlink flex /usr/bin/lex || die |
57 | } |