Contents of /smage/trunk/core/openmotif/openmotif-2.3.4-r1.smage2
Parent Directory | Revision Log
Revision 4279 -
(show annotations)
(download)
Tue Nov 13 08:02:58 2012 UTC (11 years, 7 months ago) by niro
File size: 2688 byte(s)
Tue Nov 13 08:02:58 2012 UTC (11 years, 7 months ago) by niro
File size: 2688 byte(s)
-reworked no-demos patch for 2.3.4
1 | # $Id$ |
2 | |
3 | PNAME="openmotif" |
4 | PVER="2.3.4" |
5 | PBUILD="r1" |
6 | |
7 | PCAT="x11-libs" |
8 | |
9 | DESCRIPTION="Motif is the industry standard toolkit for UNIX systems." |
10 | HOMEPAGE="http://www.motifzone.org/" |
11 | |
12 | DEPEND=">= virtual/glibc |
13 | >= x11-libs/libXmu-1.1 |
14 | >= x11-libs/libXaw-1" |
15 | |
16 | SDEPEND=">= virtual/sed |
17 | >= sys-dev/autoconf-4 |
18 | >= sys-dev/automake-3 |
19 | >= x11-proto/xextproto-1 |
20 | >= x11-misc/xbitmaps-1" |
21 | |
22 | SRCFILE="motif-${PVER}-src.tgz" |
23 | SRCDIR="${BUILDDIR}/motif-${PVER}" |
24 | |
25 | ALX_PKG_KEEP="usr/$(mlibdir)/*.so.*" |
26 | sminclude multilib mtools alx-split |
27 | |
28 | SRC_URI=( |
29 | sourceforge://motif/${SRCFILE} |
30 | mirror://${PNAME}/${SRCFILE} |
31 | mirror://${PNAME}/openmotif-2.2.3-Mwm.defaults |
32 | mirror://${PNAME}/${PNAME}-${PVER}-no-demos.patch |
33 | ) |
34 | |
35 | UP2TARBALL="motif" |
36 | UP2SUBSTITUTE="-src" |
37 | UP2DATE="updatecmd_sourceforge motif Motif tgz" |
38 | |
39 | src_prepare() |
40 | { |
41 | munpack ${SRCFILE} || die |
42 | |
43 | # disable compilation of demo binaries |
44 | mpatch ${PNAME}-${PVER}-no-demos.patch || die |
45 | |
46 | # add X.Org vendor string to aliases for virtual bindings |
47 | all-abis "echo -e '"The X.Org Foundation"\t\t\t\t\tpc' >> bindings/xmbind.alias" || die |
48 | |
49 | # add missing files to run autoconf successfully |
50 | all-abis "touch NEWS AUTHORS INSTALL COPYING" || die |
51 | mautoreconf || die |
52 | } |
53 | |
54 | src_compile() |
55 | { |
56 | # there are some issues with ${LANG} |
57 | unset LANG |
58 | |
59 | # fix some anoying warnings |
60 | export CFLAGS="${CFLAGS} -fno-strict-aliasing" |
61 | export CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing" |
62 | |
63 | mconfigure \ |
64 | --with-x \ |
65 | --disable-printing \ |
66 | --disable-xft \ |
67 | --disable-png \ |
68 | --disable-jpeg \ |
69 | || die |
70 | |
71 | # remove prebuild bison parsers |
72 | mmake clean || die |
73 | |
74 | # doesn't like optimations and fixed build with as-needed" |
75 | mmake -j1 || die |
76 | } |
77 | |
78 | alx_generic_src_install() |
79 | { |
80 | # needed directories |
81 | minstalldir /etc/X11/app-defaults || die |
82 | minstalldir /etc/X11/mwm || die |
83 | |
84 | mmake -j1 DESTDIR=${BINDIR} install || die |
85 | |
86 | # move system.mwmrc /etc/X11/mwm |
87 | mv ${BINDIR}/usr/$(mlibdir)/X11/system.mwmrc ${BINDIR}/etc/X11/mwm/system.mwmrc || die |
88 | mlink /etc/X11/mwm /usr/$(mlibdir)/X11/mwm || die |
89 | |
90 | # fix man-pages |
91 | for i in ${BINDIR}/usr/share/man/man1/mwm.1 \ |
92 | ${BINDIR}/usr/share/man/man4/mwmrc.4 |
93 | do |
94 | sed -i "s:/usr/$(mlibdir)/X11/\(.*system\\&\.mwmrc\):/etc/X11/mwm/\1:g" ${i} || die |
95 | sed -i "s:/usr/$(mlibdir)/X11/app-defaults:/etc/X11/app-defaults:g" ${i} || die |
96 | done |
97 | |
98 | # missing app-defaults |
99 | minstalletc openmotif-2.2.3-Mwm.defaults Mwm /etc/X11/app-defaults || die |
100 | |
101 | # prune unneeded stuff |
102 | all-abis '[ -e ${BINDIR}/usr/$(mlibdir)/X11/bindings ] && rm -rf ${BINDIR}/usr/$(mlibdir)/X11/bindings || die' |
103 | if [ -e ${BINDIR}/usr/include/X11/bitmaps ] |
104 | then |
105 | rm -rf ${BINDIR}/usr/include/X11/bitmaps || die |
106 | fi |
107 | |
108 | minstalldocs BUGREPORT COPYRIGHT.MOTIF LICENSE README RELEASE RELNOTES TODO || die |
109 | } |