summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2018-01-01 20:04:48 +0100
committerFabian Groffen <grobian@gentoo.org>2018-01-01 20:04:58 +0100
commit56d30f30691c40e606d848ffbafac8029750bb99 (patch)
treeeb1ef25b0cec74fe0ee4e3de51a1972e76071262 /sys-apps/darwin-miscutils
parentmedia-sound/alsaplayer: switched from media-sound/jack-audio-connection-kit t... (diff)
downloadgentoo-56d30f30691c40e606d848ffbafac8029750bb99.tar.gz
gentoo-56d30f30691c40e606d848ffbafac8029750bb99.tar.bz2
gentoo-56d30f30691c40e606d848ffbafac8029750bb99.zip
sys-apps/darwin-miscutils: version bump to High Sierra version
Add compilation fixes/patch by Michael Weiser from bug #642666. Closes: https://bugs.gentoo.org/642666 Package-Manager: Portage-2.3.13, Repoman-2.3.3
Diffstat (limited to 'sys-apps/darwin-miscutils')
-rw-r--r--sys-apps/darwin-miscutils/Manifest3
-rw-r--r--sys-apps/darwin-miscutils/darwin-miscutils-12.ebuild156
2 files changed, 159 insertions, 0 deletions
diff --git a/sys-apps/darwin-miscutils/Manifest b/sys-apps/darwin-miscutils/Manifest
index 065c7ad0c714..2bc123dcefa2 100644
--- a/sys-apps/darwin-miscutils/Manifest
+++ b/sys-apps/darwin-miscutils/Manifest
@@ -1,3 +1,4 @@
+DIST adv_cmds-md-147-compile.patch 5423 BLAKE2B f54aaaa8fcecb81fd8e628bcb384f537e572095b8210612c0748017f033e7bb6f9c5b1bd2c544fec23e8002a2ac7b99d840c85a8ca6faadac3b4da2edb77b459 SHA512 951e981b57e7d3d6ef51d638759559581dd4995ce66ec17bb2658f8a298683feb0842d10fd834b713ec39b2a0f671df56049b876d55f17bf1e988d76839fead1
DIST adv_cmds-md-147.1 3623 BLAKE2B 18b856770f0490ef241e19cc6f1661f6521bcc7f363bff41fbec548388d8f1e2d9e6aea879064cd3d7e7d16f8e0b2ff17ead990051a068a66f520a5ff504afa3 SHA512 459beb2b7c92b8718c76d744bbabf631bf8c329feb65c9434ce8a023c73ceac2d207c95e39c4b90b095a4724a74096a3d1bed9122883eb54e5311dfc64ffc718
DIST adv_cmds-md-147.c 25945 BLAKE2B 38af9e06e18a15cc74a81464a4c1ecdf98b800eb34f33f6ab6203b60540e693d459805432e51bae1008661aa566830c87357432428f62d8cbea9973b1e5fc59a SHA512 93e70f7d8697652b5a3c661975d21b51545d2eb07de64fd40524fcf0d5016dae9ae1dc63c4a85cb5ad455c8d1c246b7f5f2eac38226dcefbf4cab12b0b1c7592
DIST developer_cmds-49.tar.gz 307753 BLAKE2B 774259d7b82efc85bf487111e5a3c4c0d4aa3f8a788463b503e4d108c684837327b97882114d3646dfba5f60a1a1a2671e0e574d92e159b5ea014fc9e2c61015 SHA512 3750374c891f6d681829986291d887cacf2c5b1c7a5de94f12c92ded0b3456157b85e57653c6061526d1f6626a7be8a9e6db9c1df09e2bb3e40c7fa20b9b4103
@@ -8,8 +9,10 @@ DIST misc_cmds-23.tar.gz 114747 BLAKE2B 9c4a1376555775a6999437e0712f62200d10be97
DIST misc_cmds-27.tar.gz 116351 BLAKE2B 00aece4bc8679d9a7a1e114db65bca97e8f855ead64ee0672ac598c28069c56355f4a763fef0e56784ee9d2de9a081ef6f7e6d9390fc79cb0dec25dbe40ec881 SHA512 594560b179f7dafc651d3a336d33bcb7075f2199cf4964e95d63164faf19bd50ef3a6095124f0e4f91c50d1bceeb831fcd81ceecf740e2696a8e7445c1a690d2
DIST misc_cmds-31.tar.gz 121187 BLAKE2B 3d12a13cbdc7c541b98596ab5ea675d27a0da93a913ee94945dc5b68b3238a85c3fd13472c3ead30219ae3317a6111ba8d22a6e702fe07f927318f5174870a70 SHA512 d49bb8a49c23aa7efaa7db1958676390b4d5ef1b2e57f80b0bea0f10b8b29a6c3ec6d2d7a1248d3af77d382c5113fb3cbf9d3632ca92bb51c01d8c286fd9f25f
DIST misc_cmds-33.tar.gz 123114 BLAKE2B fb86518067b36de536503df521f1dc5e4f20fa1da74cfee4679dd728862b9ca4c1c272fd0ba39107d058f992acc04c2c98f3f44d6b2fc57386d3c458cfedd68f SHA512 34957adaebe4ce1569464a466e13aaaa6a567c582b784b99dd260c891a417d37a0297bf11acc9eb16dfabed18f42480058ae726e0a56b7d98ed93b59f75a5644
+DIST misc_cmds-34.tar.gz 124023 BLAKE2B 3c634ab540f4b1046e6abe05476a399ea00fd6d35d2d450f68cd7c3f52c8b9321039221659647b6623d5621af1789dba3798ec9f5cff8677653fbb3f295d1d1c SHA512 5e4040c49cc6aed8d4b471cc5d26d978717c9ad29315d40098090d0f7fee5a78289f2092fd6e8c7b7adea31b766cfefdef0da957b86ffb4e0781c13f4b5e4dbe
DIST shell_cmds-118.tar.gz 162145 BLAKE2B 5f6a2264bcbd9322cb50e39ac6594f083f9d0c0ffa68d67fccc6e4979c59edfab617bb7ffefb4ef647111a1abc7b855a19a1f3b309ad50a6a1f92900305ece6d SHA512 efce064b76087451293a6992b7946fb0811856275796efa9e1e30459edf9eb0462929a1f0d28d189bf7e85fdde4d9e80b8637d042497b1e6e9216c8888d0d57b
DIST shell_cmds-149.tar.gz 173740 BLAKE2B d1cc69f204925628f812acf0f69704c8c0f5b94ee9b3bd8898ec773657ee6c8a617f1666a9ce9e63898eff1cfbc915b7dfd7a91c51eebe642affa41c14f0f828 SHA512 e0f87db828c994bad73e4340f1957378ce5c84419172ed1d6b9d63809b90edfa447cce658e715565c5c2a7d2eaf0a9ee75e24fdb6d86080063621e0f83eb2a77
DIST shell_cmds-162.tar.gz 179189 BLAKE2B 975728cbfe262072c9fcc3aee457d3814ceffbd4f3f87a25e5f30d3b581c4ce05c112b2e023e1c132bc836e337e9edf74f699dc3e6cb797be5b589a3cb5eed82 SHA512 784b6b8b3a90967d79f5a60a23e7f31f7bc92712dac9cdb625770f92b58bd6902669aa19bb59997cc654fcc0e27ddd45f60b1990e7da95d0e6c90fd7f2434f95
DIST shell_cmds-170.tar.gz 212954 BLAKE2B a9616f7604bb73c0d88f8a065441c2f4769747d407458b3844e3e9126c224b42501bf546b1bc82ab6cdfc318861b43318a8a8877e7a054209cbbc7bdaaec0e24 SHA512 b267a9b5e922c9952451ca05e5f9e328504dc46b5776e1a8405f8e41a604d7f184d70742cb6fa6646875bc1789082097c74eabcc151ac5568ba26ed858269ce7
DIST shell_cmds-198.tar.gz 411088 BLAKE2B 074efebfdc0fb408df54ce763018c74370049d7c977c912c69bc399f3b3551280f1ea76fbd7205ad54ce676422c642431e297f269cafd2ee5fcb4cd916c91548 SHA512 6e3a43f0cd9b1e3799d1ba79f4fcc4c3bb9be178c35cba2bef9227ecc259ca52c39b4d0e39c71d9af689e07f48dbeee6806bd623286f116f7d3ee3889dc7c71f
+DIST shell_cmds-203.tar.gz 428799 BLAKE2B 54103daa8a8758dd34a66f9c34a5fa4cad2e6a2dd36ff838498d82179566eb95c25c49126341ac481889381c2d39ebea3bf57959bb943536a7ba8a90fcf96f67 SHA512 ba9b00d6681d286e6210d49d70e1f526e86b0a76ed794050e9cdbdb8c0cc30dbe82ee9cd908578ddabb19c53c8994f1b84650f08bfeb88ea9f77d4de942c1cb1
diff --git a/sys-apps/darwin-miscutils/darwin-miscutils-12.ebuild b/sys-apps/darwin-miscutils/darwin-miscutils-12.ebuild
new file mode 100644
index 000000000000..96a868b3409d
--- /dev/null
+++ b/sys-apps/darwin-miscutils/darwin-miscutils-12.ebuild
@@ -0,0 +1,156 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+
+inherit toolchain-funcs
+
+# from macOS 10.13
+MISC_VER=34
+SHELL_VER=203
+# from DT 8.2.1
+DEV_VER=63
+# from 10.7.4
+MD_VER=147 # adv_cmds-148 in 10.8 has no md, bug #428530
+
+DESCRIPTION="Miscellaneous commands used on macOS, High Sierra 10.13"
+HOMEPAGE="https://www.opensource.apple.com/"
+SRC_URI="https://opensource.apple.com/tarballs/misc_cmds/misc_cmds-${MISC_VER}.tar.gz
+ https://opensource.apple.com/tarballs/shell_cmds/shell_cmds-${SHELL_VER}.tar.gz
+ https://opensource.apple.com/tarballs/developer_cmds/developer_cmds-${DEV_VER}.tar.gz
+ https://opensource.apple.com/source/adv_cmds/adv_cmds-${MD_VER}/md/md.c -> adv_cmds-md-${MD_VER}.c
+ https://opensource.apple.com/source/adv_cmds/adv_cmds-${MD_VER}/md/md.1 -> adv_cmds-md-${MD_VER}.1
+ https://642666.bugs.gentoo.org/attachment.cgi?id=511988 -> adv_cmds-md-${MD_VER}-compile.patch"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc-macos ~x64-macos ~x86-macos"
+IUSE=""
+
+# for ncal
+DEPEND="sys-libs/ncurses:="
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}
+
+src_prepare() {
+ cd "${S}"/shell_cmds-${SHELL_VER} || die
+ eapply "${FILESDIR}"/${PN}-6-w64.patch
+
+ mkdir -p "${S}"/adv_cmds-${MD_VER}/md || die
+ cd "${S}"/adv_cmds-${MD_VER} || die
+ cp "${DISTDIR}"/adv_cmds-md-${MD_VER}.c md/md.c || die
+ cp "${DISTDIR}"/adv_cmds-md-${MD_VER}.1 md/md.1 || die
+ eapply "${DISTDIR}"/adv_cmds-md-${MD_VER}-compile.patch
+
+ cd "${S}"
+ eapply_user
+}
+
+src_compile() {
+ local flags=(
+ ${CFLAGS}
+ -I.
+ -D__FBSDID=__RCSID
+ -Du_int=uint32_t
+ -include stdint.h
+ )
+
+ v() {
+ echo "$*"
+ $@
+ }
+
+ local TS=${S}/misc_cmds-${MISC_VER}
+ # tsort is provided by coreutils
+ for t in leave units calendar; do
+ cd "${TS}/${t}"
+ echo "in ${TS}/${t}:"
+ v $(tc-getCC) ${flags[@]} -o ${t} ${LDFLAGS} *.c || die
+ done
+ # compile cal separately
+ cd "${TS}/ncal"
+ echo "in ${TS}/ncal:"
+ v $(tc-getCC) ${flags[@]} -c calendar.c || die
+ v $(tc-getCC) ${flags[@]} -c easter.c || die
+ v $(tc-getCC) ${flags[@]} -c ncal.c || die
+ v $(tc-getCC) -o cal ${LDFLAGS} -lncurses calendar.o easter.o ncal.o || die
+
+ TS=${S}/shell_cmds-${SHELL_VER}
+ # only pick those tools not provided by coreutils, findutils
+ for t in \
+ apply getopt hexdump hostname jot kill killall \
+ lastcomm renice script shlock time whereis;
+ do
+ echo "in ${TS}/${t}:"
+ cd "${TS}/${t}"
+ v $(tc-getCC) ${flags[@]} -o ${t} ${LDFLAGS} *.c || die
+ done
+ cd "${TS}/w"
+ sed -i -e '/#include <libutil.h>/d' w.c || die
+ echo "in ${TS}/w:"
+ v $(tc-getCC) ${flags[@]} -DHAVE_UTMPX=1 ${LDFLAGS} -lresolv -o w *.c || die
+
+ TS=${S}/developer_cmds-${DEV_VER}
+ # only pick those tools that do not conflict (no ctags and indent)
+ # do not install lorder, mkdep and vgrind as they are a non-prefix-aware
+ # shell scripts
+ # don't install rpcgen, as it is heavily related to the OS it runs
+ # on (and this is the High Sierra version)
+ for t in asa unifdef what ; do
+ echo "in ${TS}/${t}:"
+ cd "${TS}/${t}" || die
+ v $(tc-getCC) ${flags[@]} -o ${t} ${LDFLAGS} *.c || die
+ done
+
+ # provide this one for gcc-apple
+ TS=${S}/adv_cmds-${MD_VER}
+ for t in md ; do
+ echo "in ${TS}/${t}:"
+ cd "${TS}/${t}" || die
+ v $(tc-getCC) ${flags[@]} -o ${t} ${LDFLAGS} *.c || die
+ done
+}
+
+src_install() {
+ mkdir -p "${ED}"/{,usr/}bin
+
+ local TS=${S}/misc_cmds-${MISC_VER}
+ for t in leave units calendar ; do
+ cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
+ doman "${TS}/${t}/${t}.1"
+ done
+ # copy cal separately
+ cp "${TS}/ncal/cal" "${ED}"/usr/bin/ncal
+ dosym ncal /usr/bin/cal
+ doman "${TS}/ncal/ncal.1"
+ dosym ncal.1 /usr/share/man/man1/cal.1
+
+ TS=${S}/shell_cmds-${SHELL_VER}
+ for t in \
+ apply getopt hexdump hostname jot killall lastcomm \
+ renice script shlock time w whereis;
+ do
+ cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
+ [[ -f "${TS}/${t}/${t}.1" ]] && doman "${TS}/${t}/${t}.1"
+ [[ -f "${TS}/${t}/${t}.8" ]] && doman "${TS}/${t}/${t}.8"
+ done
+ cp "${TS}/w/w" "${ED}"/usr/bin/uptime
+ doman "${TS}/w/uptime.1"
+ for t in hostname kill; do
+ cp "${TS}/${t}/${t}" "${ED}"/bin/
+ doman "${TS}/${t}/${t}.1"
+ done
+
+ TS=${S}/developer_cmds-${DEV_VER}
+ for t in asa unifdef what ; do
+ cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
+ doman "${TS}/${t}/${t}.1"
+ done
+
+ TS=${S}/adv_cmds-${MD_VER}
+ for t in md ; do
+ cp "${TS}/${t}/${t}" "${ED}"/usr/bin/
+ doman "${TS}/${t}/${t}.1"
+ done
+}