summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2023-07-29 16:00:54 +0100
committerMarek Szuba <marecki@gentoo.org>2023-07-29 18:24:09 +0100
commit7d11b13abb866d68a6a43c145cede898a3e50419 (patch)
tree3e17e9c41f10134d6cfb51915af4d1a6c729a5d9 /net-misc/oidc-agent
parentmedia-gfx/darktable: add 4.4.2 (diff)
downloadgentoo-7d11b13abb866d68a6a43c145cede898a3e50419.tar.gz
gentoo-7d11b13abb866d68a6a43c145cede898a3e50419.tar.bz2
gentoo-7d11b13abb866d68a6a43c145cede898a3e50419.zip
net-misc/oidc-agent: add 4.5.2
Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'net-misc/oidc-agent')
-rw-r--r--net-misc/oidc-agent/Manifest1
-rw-r--r--net-misc/oidc-agent/files/oidc-agent-4.5.2_install-perms.patch32
-rw-r--r--net-misc/oidc-agent/oidc-agent-4.5.2.ebuild97
3 files changed, 130 insertions, 0 deletions
diff --git a/net-misc/oidc-agent/Manifest b/net-misc/oidc-agent/Manifest
index f8c5d74b05e4..e6022652a197 100644
--- a/net-misc/oidc-agent/Manifest
+++ b/net-misc/oidc-agent/Manifest
@@ -1 +1,2 @@
DIST oidc-agent-4.5.1.tar.gz 1823853 BLAKE2B d73ce4405ead08ddc0433a5c3b660b08037eecbde5f1e0358cad8731d0787e63ffae4b1317ecfe824a951e07a82d600fa4180557d93d0ce5a382e8c8f39289d6 SHA512 9afffbfcb00c610b04f97c59d610799a4ce45b1c40a61e388c6ab8b550381725602e43d219ce475a9d0425c1bc07b49ca982379286e9f48ebae1e19ca4587779
+DIST oidc-agent-4.5.2.tar.gz 1766905 BLAKE2B 0558778a5162fbbbe29be9a476838d745abf4825e7274487637f368d521e03f6f165ec82129f37f135a6cf3d3d43bb9349574b88763a508bb683cdc8882230d2 SHA512 04c9ddb258c132781eaa875412f0a8d48d2127e5b78ba262eb0240dac05025db62f5d357e4b5c35a9009960b30d63ce96156c8dcf3b5eac4257c02d37578e676
diff --git a/net-misc/oidc-agent/files/oidc-agent-4.5.2_install-perms.patch b/net-misc/oidc-agent/files/oidc-agent-4.5.2_install-perms.patch
new file mode 100644
index 000000000000..b83c934e75d9
--- /dev/null
+++ b/net-misc/oidc-agent/files/oidc-agent-4.5.2_install-perms.patch
@@ -0,0 +1,32 @@
+--- a/Makefile
++++ b/Makefile
+@@ -698,16 +698,16 @@
+ @ln -sf $(SHARED_LIB_NAME_SO) $@
+
+ $(INCLUDE_PATH)/oidc-agent/%.h: $(SRCDIR)/api/%.h $(INCLUDE_PATH)/oidc-agent
+- @install -p $< $@
++ @install -p -m 644 $< $@
+
+ $(INCLUDE_PATH)/oidc-agent/ipc_values.h: $(SRCDIR)/defines/ipc_values.h $(INCLUDE_PATH)/oidc-agent
+- @install -p $< $@
++ @install -p -m 644 $< $@
+
+ $(INCLUDE_PATH)/oidc-agent/oidc_error.h: $(SRCDIR)/utils/oidc_error.h $(INCLUDE_PATH)/oidc-agent
+- @install -p $< $@
++ @install -p -m 644 $< $@
+
+ $(LIBDEV_PATH)/liboidc-agent.a: $(APILIB)/liboidc-agent.a $(LIBDEV_PATH)
+- @install -p $< $@
++ @install -p -m 644 $< $@
+
+ endif
+
+@@ -715,7 +715,7 @@
+
+ ## scheme handler
+ $(DESKTOP_APPLICATION_PATH)/oidc-gen.desktop: $(CONFDIR)/scheme_handler/oidc-gen.desktop
+- @install -p -D $< $@
++ @install -p -m 644 -D $< $@
+ @echo "Exec=x-terminal-emulator -e bash -c \"$(BIN_AFTER_INST_PATH)/bin/$(GEN) --codeExchange=%u; exec bash\"" >> $@
+
+ ## Xsession
diff --git a/net-misc/oidc-agent/oidc-agent-4.5.2.ebuild b/net-misc/oidc-agent/oidc-agent-4.5.2.ebuild
new file mode 100644
index 000000000000..d42def7c515c
--- /dev/null
+++ b/net-misc/oidc-agent/oidc-agent-4.5.2.ebuild
@@ -0,0 +1,97 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit xdg-utils
+
+DESCRIPTION="Agent and tools for managing OpenID Connect tokens on the command line"
+HOMEPAGE="https://github.com/indigo-dc/oidc-agent"
+SRC_URI="https://github.com/indigo-dc/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~riscv"
+IUSE="test"
+
+DEPEND="app-crypt/libsecret
+ dev-libs/cJSON:=
+ dev-libs/libsodium:=
+ media-gfx/qrencode
+ net-libs/libmicrohttpd:=
+ net-libs/webkit-gtk:4.1=
+ net-misc/curl
+ elibc_musl? ( sys-libs/argp-standalone )"
+RDEPEND="${DEPEND}"
+BDEPEND="test? ( dev-libs/check )"
+
+RESTRICT="!test? ( test )"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.5.0_webkit41.patch
+ "${FILESDIR}"/${PN}-4.5.2_install-perms.patch
+)
+
+src_prepare() {
+ xdg_environment_reset
+ default
+ sed -i -e 's|^\(\s\+\)@|\1|' Makefile || die "Failed to increase verbosity in Makefile"
+}
+
+oidc_emake() {
+ local mymakeargs=(
+ USE_CJSON_SO=1
+ USE_LIST_SO=0
+ USE_MUSTACHE_SO=0
+ USE_ARGP_SO=$(usex elibc_musl 1 0)
+ )
+
+ emake "${mymakeargs[@]}" $@
+}
+
+src_compile() {
+ oidc_emake -j1 create_obj_dir_structure create_picobj_dir_structure # Bug #880157
+ oidc_emake
+}
+
+src_install() {
+ oidc_emake \
+ PREFIX="${ED}" \
+ BIN_AFTER_INST_PATH="/usr" \
+ INCLUDE_PATH="${ED}"/usr/include \
+ LIB_PATH="${ED}"/usr/$(get_libdir) \
+ install
+
+ # This file is not compatible with Gentoo and in any case, we generally
+ # let the users load such agents themselves.
+ rm -f "${ED}"/etc/X11/Xsession.d/91${PN}
+}
+
+pkg_postinst() {
+ xdg_desktop_database_update
+
+ if [[ -z "${REPLACING_VERSIONS}" ]]; then
+ elog
+ elog "You should use oidc-gen to initially generate your account configuration"
+ elog "before it can be loaded into oidc-agent using oidc-add. For details, please"
+ elog "consult the man page of oidc-gen, or full documentation at"
+ elog " https://indigo-dc.gitbooks.io/oidc-agent/"
+ elog
+ else
+ local new_major_ver old_ver
+ new_major_ver=$(ver_cut 1)
+ for old_ver in ${REPLACING_VERSIONS}; do
+ if [[ $(ver_cut 1 ${old_ver}) != ${new_major_ver} ]]; then
+ ewarn
+ ewarn "You are upgrading from a different major version. Please restart any running instances of ${PN}"
+ ewarn "to make sure they are compatible with the updated clients."
+ ewarn
+ break
+ fi
+ done
+ fi
+}
+
+pkg_postrm() {
+ xdg_desktop_database_update
+}