/[gentoo-x86]/sys-apps/darwin-miscutils/darwin-miscutils-4-r1.ebuild
Gentoo

Contents of /sys-apps/darwin-miscutils/darwin-miscutils-4-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.5 - (show annotations) (download)
Fri Mar 5 18:04:28 2010 UTC (9 years, 10 months ago) by grobian
Branch: MAIN
CVS Tags: HEAD
Changes since 1.4: +3 -3 lines
Convert to EAPI=3
(Portage version: 2.2.00.15738-prefix/cvs/Darwin powerpc)

1 # Copyright 1999-2010 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sys-apps/darwin-miscutils/darwin-miscutils-4-r1.ebuild,v 1.4 2010/01/08 08:56:43 grobian Exp $
4
5 EAPI="3"
6
7 inherit toolchain-funcs
8
9 MISC_VER=18
10 SHELL_VER=81
11 DEV_VER=39
12
13 DESCRIPTION="Miscellaneous commands used on Darwin/Mac OS X systems, Tiger"
14 HOMEPAGE="http://www.opensource.apple.com/"
15 SRC_URI="http://www.opensource.apple.com/darwinsource/tarballs/other/misc_cmds-${MISC_VER}.tar.gz
16 http://www.opensource.apple.com/darwinsource/tarballs/other/shell_cmds-${SHELL_VER}.tar.gz
17 http://www.opensource.apple.com/darwinsource/tarballs/other/developer_cmds-${DEV_VER}.tar.gz"
18
19 LICENSE="BSD"
20 SLOT="0"
21 KEYWORDS="~ppc-macos ~x64-macos ~x86-macos"
22 IUSE=""
23
24 DEPEND=""
25 RDEPEND=""
26
27 S=${WORKDIR}
28
29 src_compile() {
30 local TS=${S}/misc_cmds-${MISC_VER}
31 # tsort is provided by coreutils
32 for t in cal leave lock units calendar; do
33 cd "${TS}/${t}"
34 echo "in ${TS}/${t}:"
35 echo "$(tc-getCC) -o ${t}" *.c
36 $(tc-getCC) -o ${t} *.c || die "failed to compile $t"
37 done
38
39 TS=${S}/shell_cmds-${SHELL_VER}
40 # only pick those tools not provided by coreutils, findutils
41 for t in \
42 alias apply getopt hostname jot kill killall \
43 lastcomm renice script shlock time whereis;
44 do
45 echo "in ${TS}/${t}:"
46 echo "$(tc-getCC) -o ${t} ${t}.c"
47 cd "${TS}/${t}"
48 $(tc-getCC) -o ${t} ${t}.c || die "failed to compile $t"
49 done
50 cd "${TS}/su"
51 echo "in ${TS}/su:"
52 echo "$(tc-getCC) -lpam -o su su.c"
53 $(tc-getCC) -lpam -o su su.c || die "failed to compile su"
54 cd "${TS}/w"
55 echo "in ${TS}/w:"
56 echo "$(tc-getCC) -DSUCKAGE -lresolv -o w w.c pr_time.c proc_compare.c"
57 $(tc-getCC) -DSUCKAGE -lresolv -o w w.c pr_time.c proc_compare.c \
58 || die "failed to compile w"
59
60 TS=${S}/developer_cmds-${DEV_VER}
61 # only pick those tools that do not conflict (no ctags and indent)
62 # do not install lorder, mkdep and vgrind as they are a non-prefix-aware
63 # shell scripts
64 # don't install rpcgen, as it is heavily related to the OS it runs
65 # on (and this is the Tiger version)
66 for t in asa error hexdump unifdef what ; do
67 echo "in ${TS}/${t}:"
68 echo "$(tc-getCC) -o ${t}" *.c
69 cd "${TS}/${t}"
70 sed -i -e '/^__FBSDID/d' *.c
71 $(tc-getCC) -o ${t} *.c || die "failed to compile $t"
72 done
73 }
74
75 src_install() {
76 mkdir -p "${ED}"/bin
77 mkdir -p "${ED}"/usr/bin
78
79 local TS=${S}/misc_cmds-${MISC_VER}
80 for t in cal leave lock units calendar ; do
81 cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
82 doman "${TS}/${t}/${t}.1"
83 done
84
85 TS=${S}/shell_cmds-${SHELL_VER}
86 for t in \
87 alias apply getopt jot killall lastcomm \
88 renice script shlock su time w whereis;
89 do
90 cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
91 [[ -f "${TS}/${t}/${t}.1" ]] && doman "${TS}/${t}/${t}.1"
92 [[ -f "${TS}/${t}/${t}.8" ]] && doman "${TS}/${t}/${t}.8"
93 done
94 cp "${TS}/w/w" "${ED}"/usr/bin/uptime
95 doman "${TS}/w/uptime.1"
96 for t in hostname kill; do
97 cp "${TS}/${t}/${t}" "${ED}"/bin/
98 doman "${TS}/${t}/${t}.1"
99 done
100
101 TS=${S}/developer_cmds-${DEV_VER}
102 for t in asa error hexdump unifdef what ; do
103 cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
104 doman "${TS}/${t}/${t}.1"
105 done
106 }

  ViewVC Help
Powered by ViewVC 1.1.20