mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-09 23:23:00 -04:00
net-misc/purritobin: fix categories for usockets/uwebsockets
net-libs/usockets: move to net-libs per OpenBSD/FreeBSD www-apps/uwebsockets: move to www-apps per Open/FreeBSD Package-Manager: Portage-2.3.101, Repoman-2.3.22 Signed-off-by: Aisha Tammy <gentoo@aisha.cc>
This commit is contained in:
1
net-libs/usockets/Manifest
Normal file
1
net-libs/usockets/Manifest
Normal file
@@ -0,0 +1 @@
|
||||
DIST usockets-0.4.0.tar.gz 48367 BLAKE2B 025b83bd1f9778c469ad29bde0f8cab7fbc5f9b86e5cd97261b9aee77c2d26a67d22a185a17011e9c067acb23e0341c4112a00dbf270510013e1e863b5678ff1 SHA512 c480c6fd4a87ebe7d9db1928185075d52da63482f4ecc37f684fe10654e92de540badf47d2ab8e6021266a87308496189b39e95830d11924da0023a222decf2d
|
||||
64
net-libs/usockets/files/usockets-Makefile.patch
Normal file
64
net-libs/usockets/files/usockets-Makefile.patch
Normal file
@@ -0,0 +1,64 @@
|
||||
diff --git a/Makefile b/Makefile
|
||||
index fa6e2ff..529ed74 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -1,3 +1,14 @@
|
||||
+DESTDIR ?=
|
||||
+
|
||||
+prefix ?= "/usr/local"
|
||||
+exec_prefix ?= "$(prefix)"
|
||||
+libdir ?= "$(exec_prefix)/lib"
|
||||
+includedir?= "$(exec_prefix)/include/uSockets"
|
||||
+
|
||||
+# OpenBSD specific library version
|
||||
+LIBTARGET = libusockets.so.$(LIBusockets_VERSION)
|
||||
+
|
||||
+
|
||||
# WITH_OPENSSL=1 enables OpenSSL 1.1+ support
|
||||
ifeq ($(WITH_OPENSSL),1)
|
||||
override CFLAGS += -DLIBUS_USE_OPENSSL
|
||||
@@ -33,13 +44,33 @@ ifeq ($(WITH_ASAN),1)
|
||||
endif
|
||||
|
||||
override CFLAGS += -std=c11 -Isrc
|
||||
-override LDFLAGS += uSockets.a
|
||||
|
||||
-# By default we build the uSockets.a static library
|
||||
-default:
|
||||
+static:
|
||||
rm -f *.o
|
||||
- $(CC) $(CFLAGS) -flto -O3 -c src/*.c src/eventing/*.c src/crypto/*.c
|
||||
- $(AR) rvs uSockets.a *.o
|
||||
+ $(CC) $(CFLAGS) -c src/*.c src/eventing/*.c src/crypto/*.c
|
||||
+ $(AR) rvs libusockets.a *.o
|
||||
+
|
||||
+dynamic:
|
||||
+ rm -f *.o
|
||||
+ $(CC) -fPIC -c src/*.c src/eventing/*.c src/crypto/*.c $(CFLAGS)
|
||||
+ $(CC) -shared -fPIC -Wl,-soname,$(LIBTARGET) $(CFLAGS) -o $(LIBTARGET) *.o $(LDFLAGS)
|
||||
+
|
||||
+default: static dynamic
|
||||
+
|
||||
+install:
|
||||
+ # install the folders needed (making sure that the exist)
|
||||
+ install -d "$(DESTDIR)$(libdir)" \
|
||||
+ "$(DESTDIR)$(includedir)/internal/eventing" \
|
||||
+ "$(DESTDIR)$(includedir)/internal/networking"
|
||||
+ # OpenBSD specific library version
|
||||
+ install -m 755 $(LIBTARGET) "$(DESTDIR)$(libdir)/"
|
||||
+ # install static library
|
||||
+ install -m 755 libusockets.a "$(DESTDIR)$(libdir)/"
|
||||
+ # we also install all the header files
|
||||
+ install src/*.h "$(DESTDIR)$(includedir)/"
|
||||
+ install -m 644 src/internal/*.h "$(DESTDIR)$(includedir)/internal/"
|
||||
+ install -m 644 src/internal/eventing/*.h "$(DESTDIR)$(includedir)/internal/eventing/"
|
||||
+ install -m 644 src/internal/networking/*.h "$(DESTDIR)$(includedir)/internal/networking/"
|
||||
|
||||
# Builds all examples
|
||||
.PHONY: examples
|
||||
@@ -52,4 +83,5 @@ swift_examples:
|
||||
clean:
|
||||
rm -f *.o
|
||||
rm -f *.a
|
||||
+ rm -f *.so
|
||||
rm -rf .certs
|
||||
11
net-libs/usockets/metadata.xml
Normal file
11
net-libs/usockets/metadata.xml
Normal file
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>gentoo@aisha.cc</email>
|
||||
<name>Aisha Tammy</name>
|
||||
</maintainer>
|
||||
<use>
|
||||
<flag name="libuv">Enable bindings to use the libuv dispatcher</flag>
|
||||
</use>
|
||||
</pkgmetadata>
|
||||
56
net-libs/usockets/usockets-0.4.0.ebuild
Normal file
56
net-libs/usockets/usockets-0.4.0.ebuild
Normal file
@@ -0,0 +1,56 @@
|
||||
# Copyright 2019-2020 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=7
|
||||
|
||||
inherit multilib
|
||||
|
||||
DESCRIPTION="tiny eventing, networking & crypto for async applications"
|
||||
HOMEPAGE="https://github.com/uNetworking/uSockets"
|
||||
|
||||
if [[ ${PV} == 9999 ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/uNetworking/uSockets.git"
|
||||
else
|
||||
SRC_URI="https://github.com/uNetworking/uSockets/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
KEYWORDS="~amd64 ~arm64 ~x86"
|
||||
S="${WORKDIR}/uSockets-${PV}"
|
||||
fi
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
IUSE="libuv +ssl libressl static-libs"
|
||||
|
||||
DEPEND="ssl? (
|
||||
libressl? ( >=dev-libs/libressl-3.0.0:=[static-libs?] )
|
||||
!libressl? ( >=dev-libs/openssl-1.1.0:=[static-libs?] )
|
||||
)
|
||||
libuv? ( dev-libs/libuv[static-libs?] )
|
||||
"
|
||||
BDEPEND="${DEPEND}"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/usockets-Makefile.patch"
|
||||
)
|
||||
|
||||
src_compile() {
|
||||
# the Makefile uses environment variables
|
||||
emake -j1 \
|
||||
LIBusockets_VERSION=${PV} \
|
||||
WITH_OPENSSL=$(usex ssl 1 0) \
|
||||
WITH_LIBUV=$(usex libuv 1 0) \
|
||||
default
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake -j1 \
|
||||
libdir="/usr/$(get_libdir)" \
|
||||
prefix="/usr" DESTDIR="${D}" \
|
||||
LIBusockets_VERSION=${PV} \
|
||||
install
|
||||
einstalldocs
|
||||
if ! use static-libs; then
|
||||
rm "${D}/usr/$(get_libdir)/libusockets.a" || die
|
||||
fi
|
||||
}
|
||||
56
net-libs/usockets/usockets-9999.ebuild
Normal file
56
net-libs/usockets/usockets-9999.ebuild
Normal file
@@ -0,0 +1,56 @@
|
||||
# Copyright 2019-2020 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=7
|
||||
|
||||
inherit multilib
|
||||
|
||||
DESCRIPTION="tiny eventing, networking & crypto for async applications"
|
||||
HOMEPAGE="https://github.com/uNetworking/uSockets"
|
||||
|
||||
if [[ ${PV} == 9999 ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/uNetworking/uSockets.git"
|
||||
else
|
||||
SRC_URI="https://github.com/uNetworking/uSockets/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
KEYWORDS="~amd64 ~arm64 ~x86"
|
||||
S="${WORKDIR}/uSockets-${PV}"
|
||||
fi
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
IUSE="libuv +ssl libressl static-libs"
|
||||
|
||||
DEPEND="ssl? (
|
||||
libressl? ( >=dev-libs/libressl-3.0.0:=[static-libs?] )
|
||||
!libressl? ( >=dev-libs/openssl-1.1.0:=[static-libs?] )
|
||||
)
|
||||
libuv? ( dev-libs/libuv[static-libs?] )
|
||||
"
|
||||
BDEPEND="${DEPEND}"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/usockets-Makefile.patch"
|
||||
)
|
||||
|
||||
src_compile() {
|
||||
# the Makefile uses environment variables
|
||||
emake -j1 \
|
||||
LIBusockets_VERSION=${PV} \
|
||||
WITH_OPENSSL=$(usex ssl 1 0) \
|
||||
WITH_LIBUV=$(usex libuv 1 0) \
|
||||
default
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake -j1 \
|
||||
libdir="/usr/$(get_libdir)" \
|
||||
prefix="/usr" DESTDIR="${D}" \
|
||||
LIBusockets_VERSION=${PV} \
|
||||
install
|
||||
einstalldocs
|
||||
if ! use static-libs; then
|
||||
rm "${D}/usr/$(get_libdir)/libusockets.a" || die
|
||||
fi
|
||||
}
|
||||
Reference in New Issue
Block a user