From 76d6a39a737b18a6664a5f83898de0414de892d4 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Wed, 13 Nov 2019 11:26:13 +0100 Subject: [PATCH] sys-kernel/xnu-headers: include some more system headers Package-Manager: Portage-2.3.76, Repoman-2.3.16 Signed-off-by: Fabian Groffen --- ...build => xnu-headers-3789.70.16-r2.ebuild} | 58 ++++++++++++++++--- ...ebuild => xnu-headers-4570.71.2-r2.ebuild} | 58 ++++++++++++++++--- ...build => xnu-headers-4903.241.1-r2.ebuild} | 58 ++++++++++++++++--- 3 files changed, 153 insertions(+), 21 deletions(-) rename sys-kernel/xnu-headers/{xnu-headers-3789.70.16-r1.ebuild => xnu-headers-3789.70.16-r2.ebuild} (54%) rename sys-kernel/xnu-headers/{xnu-headers-4570.71.2-r1.ebuild => xnu-headers-4570.71.2-r2.ebuild} (54%) rename sys-kernel/xnu-headers/{xnu-headers-4903.241.1-r1.ebuild => xnu-headers-4903.241.1-r2.ebuild} (54%) diff --git a/sys-kernel/xnu-headers/xnu-headers-3789.70.16-r1.ebuild b/sys-kernel/xnu-headers/xnu-headers-3789.70.16-r2.ebuild similarity index 54% rename from sys-kernel/xnu-headers/xnu-headers-3789.70.16-r1.ebuild rename to sys-kernel/xnu-headers/xnu-headers-3789.70.16-r2.ebuild index 6368a081634a..64fd0c53ce05 100644 --- a/sys-kernel/xnu-headers/xnu-headers-3789.70.16-r1.ebuild +++ b/sys-kernel/xnu-headers/xnu-headers-3789.70.16-r2.ebuild @@ -38,24 +38,37 @@ src_compile() { src_install() { insinto /usr/include doins EXTERNAL_HEADERS/AssertMacros.h EXTERNAL_HEADERS/Availability*.h + doins libsyscall/wrappers/gethostuuid.h + doins -r libsyscall/mach/mach # generated during src_compile insinto /usr/include/sys doins syscall.h _posix_availability.h _symbol_aliasing.h - cd bsd || die + pushd bsd > /dev/null || die + + get_files_list() { + local s="$1" + local f="$2"/Makefile + sed -n -e '/^'"${s}"' \?=/,/^$/p' "${f}" \ + | sed -e '1s/^'"${s}"' \?=//' -e '/\s*#/d' \ + | sed -e 's/\\$//' -e '/^[A-Z]\+ \?=/,/^$/d' + } get_datafiles() { - local f="$1"/Makefile - sed -n -e '/^DATAFILES \?=/,/^$/p' "${f}" \ - | sed -e '1s/^DATAFILES \?=//' -e '/\s*#/d' \ - | sed -e 's/\\$//' + local entry + get_files_list DATAFILES "$@" | while read entry ; do + [[ ${entry} == '${'?*'}' ]] \ + && get_files_list ${entry:2:-1} "$@" \ + || echo "${entry}" + done } local d local files - for d in i386 machine miscfs/{devfs,specfs,union} net \ - netinet{,6} netkey nfs sys{,/_types} uuid vfs ; do + for d in bsm i386 machine miscfs/{devfs,specfs,union} net \ + netinet{,6} netkey nfs sys{,/_types} uuid vfs ; + do insinto /usr/include/${d} files=( $(get_datafiles ${d}) ) einfo "${d}:" ${files[*]} @@ -63,4 +76,35 @@ src_install() { done use man && doman man/man*/*.[234579] + + popd > /dev/null || die + + pushd osfmk > /dev/null || die + + for d in mach{,/i386,/machine} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + for d in i386 ; do + insinto /usr/include/${d} + files=( $(get_files_list INSTALL_MD_LIST ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die + + pushd libkern > /dev/null || die + + for d in libkern{,/i386,/machine,/c++,/crypto} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die } diff --git a/sys-kernel/xnu-headers/xnu-headers-4570.71.2-r1.ebuild b/sys-kernel/xnu-headers/xnu-headers-4570.71.2-r2.ebuild similarity index 54% rename from sys-kernel/xnu-headers/xnu-headers-4570.71.2-r1.ebuild rename to sys-kernel/xnu-headers/xnu-headers-4570.71.2-r2.ebuild index 406e29dca627..706a54fbe08a 100644 --- a/sys-kernel/xnu-headers/xnu-headers-4570.71.2-r1.ebuild +++ b/sys-kernel/xnu-headers/xnu-headers-4570.71.2-r2.ebuild @@ -38,24 +38,37 @@ src_compile() { src_install() { insinto /usr/include doins EXTERNAL_HEADERS/AssertMacros.h EXTERNAL_HEADERS/Availability*.h + doins libsyscall/wrappers/gethostuuid.h + doins -r libsyscall/mach/mach # generated during src_compile insinto /usr/include/sys doins syscall.h _posix_availability.h _symbol_aliasing.h - cd bsd || die + pushd bsd > /dev/null || die + + get_files_list() { + local s="$1" + local f="$2"/Makefile + sed -n -e '/^'"${s}"' \?=/,/^$/p' "${f}" \ + | sed -e '1s/^'"${s}"' \?=//' -e '/\s*#/d' \ + | sed -e 's/\\$//' -e '/^[A-Z]\+ \?=/,/^$/d' + } get_datafiles() { - local f="$1"/Makefile - sed -n -e '/^DATAFILES \?=/,/^$/p' "${f}" \ - | sed -e '1s/^DATAFILES \?=//' -e '/\s*#/d' \ - | sed -e 's/\\$//' + local entry + get_files_list DATAFILES "$@" | while read entry ; do + [[ ${entry} == '${'?*'}' ]] \ + && get_files_list ${entry:2:-1} "$@" \ + || echo "${entry}" + done } local d local files - for d in arm i386 machine miscfs/{devfs,specfs,union} net \ - netinet{,6} netkey nfs sys{,/_types} uuid vfs ; do + for d in arm bsm i386 machine miscfs/{devfs,specfs,union} net \ + netinet{,6} netkey nfs sys{,/_types} uuid vfs ; + do insinto /usr/include/${d} files=( $(get_datafiles ${d}) ) einfo "${d}:" ${files[*]} @@ -63,4 +76,35 @@ src_install() { done use man && doman man/man*/*.[234579] + + popd > /dev/null || die + + pushd osfmk > /dev/null || die + + for d in mach{,/arm,/i386,/machine} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + for d in i386 ; do + insinto /usr/include/${d} + files=( $(get_files_list INSTALL_MD_LIST ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die + + pushd libkern > /dev/null || die + + for d in libkern{,/arm,/i386,/machine,/c++,/crypto} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die } diff --git a/sys-kernel/xnu-headers/xnu-headers-4903.241.1-r1.ebuild b/sys-kernel/xnu-headers/xnu-headers-4903.241.1-r2.ebuild similarity index 54% rename from sys-kernel/xnu-headers/xnu-headers-4903.241.1-r1.ebuild rename to sys-kernel/xnu-headers/xnu-headers-4903.241.1-r2.ebuild index cfe5c3e1d6c2..208bdea9b248 100644 --- a/sys-kernel/xnu-headers/xnu-headers-4903.241.1-r1.ebuild +++ b/sys-kernel/xnu-headers/xnu-headers-4903.241.1-r2.ebuild @@ -38,24 +38,37 @@ src_compile() { src_install() { insinto /usr/include doins EXTERNAL_HEADERS/AssertMacros.h EXTERNAL_HEADERS/Availability*.h + doins libsyscall/wrappers/gethostuuid.h + doins -r libsyscall/mach/mach # generated during src_compile insinto /usr/include/sys doins syscall.h _posix_availability.h _symbol_aliasing.h - cd bsd || die + pushd bsd > /dev/null || die + + get_files_list() { + local s="$1" + local f="$2"/Makefile + sed -n -e '/^'"${s}"' \?=/,/^$/p' "${f}" \ + | sed -e '1s/^'"${s}"' \?=//' -e '/\s*#/d' \ + | sed -e 's/\\$//' -e '/^[A-Z]\+ \?=/,/^$/d' + } get_datafiles() { - local f="$1"/Makefile - sed -n -e '/^DATAFILES \?=/,/^$/p' "${f}" \ - | sed -e '1s/^DATAFILES \?=//' -e '/\s*#/d' \ - | sed -e 's/\\$//' + local entry + get_files_list DATAFILES "$@" | while read entry ; do + [[ ${entry} == '${'?*'}' ]] \ + && get_files_list ${entry:2:-1} "$@" \ + || echo "${entry}" + done } local d local files - for d in arm i386 machine miscfs/{devfs,specfs,union} net \ - netinet{,6} netkey nfs sys{,/_types} uuid vfs ; do + for d in arm bsm i386 machine miscfs/{devfs,specfs,union} net \ + netinet{,6} netkey nfs sys{,/_types} uuid vfs ; + do insinto /usr/include/${d} files=( $(get_datafiles ${d}) ) einfo "${d}:" ${files[*]} @@ -63,4 +76,35 @@ src_install() { done use man && doman man/man*/*.[234579] + + popd > /dev/null || die + + pushd osfmk > /dev/null || die + + for d in mach{,/arm,/i386,/machine} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + for d in i386 ; do + insinto /usr/include/${d} + files=( $(get_files_list INSTALL_MD_LIST ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die + + pushd libkern > /dev/null || die + + for d in libkern{,/arm,/i386,/machine,/c++,/crypto} ; do + insinto /usr/include/${d} + files=( $(get_datafiles ${d}) ) + einfo "${d}:" ${files[*]} + doins ${files[@]/#/$d/} + done + + popd > /dev/null || die } -- 2.26.2