summaryrefslogtreecommitdiff
path: root/sys-libs/timezone-data
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-11-30 07:22:57 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-11-30 07:22:57 +0000
commit3059f20995d5ac642b7b4a38d538fdf1cc45d90d (patch)
tree8d4c6b1c09f03338eef1359de3dfeec28ea11644 /sys-libs/timezone-data
parentf616ce4660c92a3fcb4f05663c2ab47c9defa0c3 (diff)
gentoo auto-resync : 30:11:2022 - 07:22:56
Diffstat (limited to 'sys-libs/timezone-data')
-rw-r--r--sys-libs/timezone-data/Manifest3
-rw-r--r--sys-libs/timezone-data/timezone-data-2022g.ebuild197
2 files changed, 200 insertions, 0 deletions
diff --git a/sys-libs/timezone-data/Manifest b/sys-libs/timezone-data/Manifest
index 4b9a19299a5e..a6e68211e116 100644
--- a/sys-libs/timezone-data/Manifest
+++ b/sys-libs/timezone-data/Manifest
@@ -1,6 +1,9 @@
AUX timezone-data-2022f-musl.patch 6278 BLAKE2B 3d05353a3c93766e36c2e54be39ecbd44e499b9455ae896182f39de8cdbb9e96714631b38705f9845ef00cabc38fdeaeffec0b6fd7815d422749027f7076387a SHA512 9c861038af92866627071cef20745fe0dc169046cbb04922838c194ca5e4f3a4cd151b7628838d927318a23d88a21127988a5a71b14cc81c1f515bd3d61751bf
DIST tzcode2022f.tar.gz 284816 BLAKE2B 3bfcc25323edbdd41aadcbb5c8b0d9179a809a87b22afc9dda88a53c6daab742778956af7aa30722429d34601fb2ad3c4222c48497e0a429926cd05b79b9acfb SHA512 3e2ef91b972f1872e3e8da9eae9d1c4638bfdb32600f164484edd7147be45a116db80443cd5ae61b5c34f8b841e4362f4beefd957633f6cc9b7def543ed6752b
+DIST tzcode2022g.tar.gz 287901 BLAKE2B b67bb2020913c57cc6bc68d231c53ba645b95305256065e2645bce3b0d71adfaea865ed9bf40f1ec3b4a73aad7e6c48f5ecd0895de6e2d69bed6113d6b579e26 SHA512 5188edd8d05238a88da734cf78fadfb57640d4db3e7a0a9dddd70e3071e16b6eebc2e2ab17109b7dafafae68abfbc857df481cfdc3ffe63f7eb1569ea0b5997a
DIST tzdata2022f.tar.gz 436352 BLAKE2B 8081972005ac84034957bb85013b373df67937c3f811e33c44fad7ecee0f504b946766fdb1f525d0512b9a8d8e727ee3d8d44640ff55bed3fcd1f3fb3c464c17 SHA512 72d05d05be999075cdf57b896c0f4238b1b862d4d0ed92cc611736592a4ada14d47bd7f0fc8be39e7938a7f5940a903c8af41e87859482bcfab787d889d429f6
+DIST tzdata2022g.tar.gz 439731 BLAKE2B 582b79cc2317d27f3883042cbca25801397d9e2808ad8d3a340017d635372ef20316ce646a25a43b0ea5d4024841b54925ecc4510613295c39c28647989645cb SHA512 7f79394295e00e3a24ebdbf9af3bc454a65f432a93b517e7e96c7f9db9949f6f5fdae9892a9d3789ff44ae0eb1bfe4744d36976b4624659af951d26414f94e65
EBUILD timezone-data-2022f-r1.ebuild 5404 BLAKE2B 79f29b58dd33dc80b5a9307f39c4cb8797d37b5e4281e5bd6b0f566744932f06f196ecbaa1349f63eb5bc965a8363a4807ac07e263b034b0d3a8c11838c6b978 SHA512 e3da2dffffbec3cb0bc6e0a866ea274a7a247285d8a269941bad131cc46ee157ce545c5bf76343b681317e6ab85ebf32ca5dbdf904787ad270a3daefbc14ba67
EBUILD timezone-data-2022f.ebuild 5360 BLAKE2B b5de4f3fa1dd5597588b77417beb804b93993d541e518257c67e48c82891dad4a9fe23b991d817267ffd2ae61680818e2d8879ef3d0e5c799a35e36b663302a0 SHA512 c0053d962645131ebebe8d8053c2f7f1a80bbb3842a18e60b3ef8a563a377e0d5a4153335d6135f969207c90ab85ef17e122f209b27cab27769ed29e2a5265bf
+EBUILD timezone-data-2022g.ebuild 5368 BLAKE2B 4e442e464552356b906d9df9de0e685c293a3b01003131332c6084955d833e400397b47ddeef9b225dd41566169e2e4ce26abda933b7e78507a006f6e2a59ac1 SHA512 404691c964f8735e2764643518e36925442f2b041731d4935cc13b4b377823d275c1753af2b55d9a9667d14b97f182a2a7d48c35e1ba5cbb91a02a33532ccece
MISC metadata.xml 807 BLAKE2B 24b09c4228c232b607e6e6c165a20e364136d77aa970e72c70124636a038cd3b672bad16ddd68c0b75373be6a09f969e59bc38f7e451bb2869cd46c521e2ca82 SHA512 0b95b32d79651493a04032f175f3320d8975cea714b43fa56aa528f10f51a7c52b58a934828f98a770855485af6f8db048bd2bfa3010802cff8c26ae05bb16e2
diff --git a/sys-libs/timezone-data/timezone-data-2022g.ebuild b/sys-libs/timezone-data/timezone-data-2022g.ebuild
new file mode 100644
index 000000000000..190c46867d53
--- /dev/null
+++ b/sys-libs/timezone-data/timezone-data-2022g.ebuild
@@ -0,0 +1,197 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit toolchain-funcs flag-o-matic
+
+MY_CODE_VER=${PV}
+MY_DATA_VER=${PV}
+DESCRIPTION="Timezone data (/usr/share/zoneinfo) and utilities (tzselect/zic/zdump)"
+HOMEPAGE="https://www.iana.org/time-zones"
+SRC_URI="https://www.iana.org/time-zones/repository/releases/tzdata${MY_DATA_VER}.tar.gz
+ https://www.iana.org/time-zones/repository/releases/tzcode${MY_CODE_VER}.tar.gz"
+
+LICENSE="BSD public-domain"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+IUSE="nls leaps-timezone zic-slim"
+
+DEPEND="nls? ( virtual/libintl )"
+RDEPEND="
+ ${DEPEND}
+ !sys-libs/glibc[vanilla(+)]
+"
+
+src_unpack() {
+ mkdir "${S}" && cd "${S}" || die
+ default
+}
+
+src_prepare() {
+ default
+
+ # check_web contacts validator.w3.org
+ sed -i -e 's/check_tables check_web/check_tables/g' \
+ Makefile || die "Failed to disable check_web"
+
+ if tc-is-cross-compiler ; then
+ cp -pR "${S}" "${S}"-native || die
+ fi
+}
+
+src_configure() {
+ tc-export CC
+
+ # bug #471102
+ append-lfs-flags
+
+ if use elibc_Darwin ; then
+ # bug #138251
+ append-cppflags -DSTD_INSPIRED
+ fi
+
+ append-cppflags -DHAVE_GETTEXT=$(usex nls 1 0) -DTZ_DOMAIN='\"libc\"'
+
+ # Upstream default is 'slim', but it breaks quite a few programs
+ # that parse /etc/localtime directly: bug #747538.
+ append-cppflags -DZIC_BLOAT_DEFAULT='\"'$(usex zic-slim slim fat)'\"'
+
+ LDLIBS=""
+ if use nls ; then
+ # See if an external libintl is available. bug #154181, bug #578424
+ local c="${T}/test"
+ echo 'main(){}' > "${c}.c" || die
+ if $(tc-getCC) ${CPPFLAGS} ${CFLAGS} ${LDFLAGS} "${c}.c" -o "${c}" -lintl 2>/dev/null ; then
+ LDLIBS+=" -lintl"
+ fi
+ fi
+}
+
+_emake() {
+ emake \
+ REDO=$(usex leaps-timezone posix_right posix_only) \
+ TOPDIR="${EPREFIX}" \
+ ZICDIR='$(TOPDIR)/usr/bin' \
+ "$@"
+}
+
+src_compile() {
+ _emake \
+ AR="$(tc-getAR)" \
+ cc="$(tc-getCC)" \
+ RANLIB="$(tc-getRANLIB)" \
+ CFLAGS="${CFLAGS} -std=gnu99 ${CPPFLAGS}" \
+ LDFLAGS="${LDFLAGS}" \
+ LDLIBS="${LDLIBS}"
+
+ if tc-is-cross-compiler ; then
+ _emake -C "${S}"-native \
+ AR="$(tc-getBUILD_AR)" \
+ cc="$(tc-getBUILD_CC)" \
+ RANLIB="$(tc-getBUILD_RANLIB)" \
+ CFLAGS="${BUILD_CFLAGS} ${BUILD_CPPFLAGS}" \
+ LDFLAGS="${BUILD_LDFLAGS}" \
+ LDLIBS="${LDLIBS}" \
+ zic
+ fi
+}
+
+src_test() {
+ # VALIDATE_ENV is used for extended/web based tests. Punt on them.
+ emake check VALIDATE_ENV=true
+}
+
+src_install() {
+ local zic=""
+ tc-is-cross-compiler && zic="zic=${S}-native/zic"
+ _emake install ${zic} DESTDIR="${D}" LIBDIR="/nukeit"
+ rm -rf "${D}/nukeit" "${ED}/etc" || die
+
+ insinto /usr/share/zoneinfo
+ doins "${S}"/leap-seconds.list
+
+ # Delete man pages installed by man-pages package.
+ rm "${ED}"/usr/share/man/man5/tzfile.5* "${ED}"/usr/share/man/man8/{tzselect,zdump,zic}.8 || die
+ dodoc CONTRIBUTING README NEWS *.html
+}
+
+get_TIMEZONE() {
+ local tz src="${EROOT}/etc/timezone"
+ if [[ -e ${src} ]] ; then
+ tz=$(sed -e 's:#.*::' -e 's:[[:space:]]*::g' -e '/^$/d' "${src}")
+ else
+ tz="FOOKABLOIE"
+ fi
+
+ [[ -z ${tz} ]] && return 1 || echo "${tz}"
+}
+
+pkg_preinst() {
+ local tz=$(get_TIMEZONE)
+ if [[ ${tz} == right/* || ${tz} == posix/* ]] ; then
+ eerror "The right & posix subdirs are no longer installed as subdirs -- they have been"
+ eerror "relocated to match upstream paths as sibling paths. Further, posix/xxx is the"
+ eerror "same as xxx, so you should simply drop the posix/ prefix. You also should not"
+ eerror "be using right/xxx for the system timezone as it breaks programs."
+ die "Please fix your timezone setting"
+ fi
+
+ # Trim the symlink by hand to avoid portage's automatic protection checks.
+ rm -f "${EROOT}"/usr/share/zoneinfo/posix
+}
+
+configure_tz_data() {
+ # Make sure the /etc/localtime file does not get stale, bug #127899
+ local tz src="${EROOT}/etc/timezone" etc_lt="${EROOT}/etc/localtime"
+
+ # If it's a symlink, assume the user knows what they're doing and
+ # they're managing it themselves, bug #511474
+ if [[ -L "${etc_lt}" ]] ; then
+ einfo "Assuming your ${etc_lt} symlink is what you want; skipping update."
+ return 0
+ fi
+
+ if ! tz=$(get_TIMEZONE) ; then
+ einfo "Assuming your empty ${src} file is what you want; skipping update."
+ return 0
+ fi
+
+ if [[ "${tz}" == "FOOKABLOIE" ]] ; then
+ einfo "You do not have a timezone set in ${src}; skipping update."
+ return 0
+ fi
+
+ local tzpath="${EROOT}/usr/share/zoneinfo/${tz}"
+
+ if [[ ! -e ${tzpath} ]]; then
+ ewarn "The timezone specified in ${src} is not valid!"
+ return 1
+ fi
+
+ if [[ -f ${etc_lt} ]]; then
+ # If a regular file already exists, copy over it.
+ ewarn "Found a regular file at ${etc_lt}."
+ ewarn "Some software may expect a symlink instead."
+ ewarn "You may convert it to a symlink by removing the file and running:"
+ ewarn " emerge --config sys-libs/timezone-data"
+ einfo "Copying ${tzpath} to ${etc_lt}."
+ cp -f "${tzpath}" "${etc_lt}"
+ else
+ # Otherwise, create a symlink and remove the timezone file.
+ tzpath="../usr/share/zoneinfo/${tz}"
+ einfo "Linking ${tzpath} at ${etc_lt}."
+ if ln -snf "${tzpath}" "${etc_lt}"; then
+ einfo "Removing ${src}."
+ rm -f "${src}"
+ fi
+ fi
+}
+
+pkg_config() {
+ configure_tz_data
+}
+
+pkg_postinst() {
+ configure_tz_data
+}