From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 6963C1382C5 for ; Mon, 15 Feb 2021 07:11:18 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B0030E0A81; Mon, 15 Feb 2021 07:11:17 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8DF05E0A81 for ; Mon, 15 Feb 2021 07:11:17 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 4FA1F340D8E for ; Mon, 15 Feb 2021 07:11:15 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 9D50F4DE for ; Mon, 15 Feb 2021 07:11:12 +0000 (UTC) From: "Andrew Ammerlaan" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andrew Ammerlaan" Message-ID: <1613341195.5b03312f2fe5d1121be27f0f9fb8fe1fa0fcfbf3.andrewammerlaan@gentoo> Subject: [gentoo-commits] repo/proj/guru:master commit in: net-libs/usockets/, net-libs/usockets/files/ X-VCS-Repository: repo/proj/guru X-VCS-Files: net-libs/usockets/Manifest net-libs/usockets/files/usockets-0.7.1-Makefile.patch net-libs/usockets/usockets-0.7.1.ebuild net-libs/usockets/usockets-9999.ebuild X-VCS-Directories: net-libs/usockets/files/ net-libs/usockets/ X-VCS-Committer: andrewammerlaan X-VCS-Committer-Name: Andrew Ammerlaan X-VCS-Revision: 5b03312f2fe5d1121be27f0f9fb8fe1fa0fcfbf3 X-VCS-Branch: master Date: Mon, 15 Feb 2021 07:11:12 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: b824d3f9-0780-46ab-a26d-85b404d347da X-Archives-Hash: f02a0340e1b1b9339a18aaa3ea96b595 commit: 5b03312f2fe5d1121be27f0f9fb8fe1fa0fcfbf3 Author: Aisha Tammy aisha cc> AuthorDate: Sun Feb 14 22:17:34 2021 +0000 Commit: Andrew Ammerlaan riseup net> CommitDate: Sun Feb 14 22:19:55 2021 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=5b03312f net-libs/usockets: version bump to 0.7.1 Package-Manager: Portage-3.0.14, Repoman-3.0.2 Signed-off-by: Aisha Tammy aisha.cc> net-libs/usockets/Manifest | 1 + .../usockets/files/usockets-0.7.1-Makefile.patch | 124 +++++++++++++++++++++ ...{usockets-9999.ebuild => usockets-0.7.1.ebuild} | 7 +- net-libs/usockets/usockets-9999.ebuild | 7 +- 4 files changed, 131 insertions(+), 8 deletions(-) diff --git a/net-libs/usockets/Manifest b/net-libs/usockets/Manifest index ffe05544..8ef09f26 100644 --- a/net-libs/usockets/Manifest +++ b/net-libs/usockets/Manifest @@ -1 +1,2 @@ DIST usockets-0.6.0_p20210126.tar.gz 57764 BLAKE2B 3ddcfaa684dec96a80f81424512bbd7a2fd8dd0724a0c20628aa76b5bb3e5b2177402b33feb8d046f3fa813288d3d3a5b8b18d7df8bd6a28b029162cdbe3b9ab SHA512 047b95a125b0a79ee4b301bb0c718aded6d6dbcafef64965ad6bcf14428b6569e67c2a9eb3d6d4bf3a2f4e2e46e978555507dec9047e6497823a880ae7deed03 +DIST usockets-0.7.1.tar.gz 62337 BLAKE2B 84f4274e560fae5bd12d22c87d0c44234421939ec978218b094848506448b622d32648d6f5163e95abf956f18bd6e26ffc58e27403572e49295572fd0f8eed32 SHA512 06e5ae094fd07b623d65dfcb3168cf6dcd115fc41c8af1858527be6bef08cbfa432a87021c32e7b3c87d56662a32a971b08b3b2934e91b822cf68407951015ed diff --git a/net-libs/usockets/files/usockets-0.7.1-Makefile.patch b/net-libs/usockets/files/usockets-0.7.1-Makefile.patch new file mode 100644 index 00000000..4d3d2045 --- /dev/null +++ b/net-libs/usockets/files/usockets-0.7.1-Makefile.patch @@ -0,0 +1,124 @@ +diff --git a/Makefile b/Makefile +index 9b54cac..c31e575 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,60 +1,59 @@ ++DESTDIR ?= ++ ++prefix ?= /usr ++exec_prefix ?= $(prefix) ++LIB ?= lib ++libdir ?= $(exec_prefix)/$(LIB) ++includedir ?= $(exec_prefix)/include ++ ++PKG_CONFIG ?= pkg-config ++ ++VERSION ?= 0.0 ++LIBTARGET = libusockets.so.$(VERSION) ++ ++REQUIRES = ++COMMON_FLAGS = -Isrc ++ + # WITH_OPENSSL=1 enables OpenSSL 1.1+ support or BoringSSL + # For now we need to link with C++ for OpenSSL support, but should be removed with time + ifeq ($(WITH_OPENSSL),1) +- override CFLAGS += -DLIBUS_USE_OPENSSL +- # With problems on macOS, make sure to pass needed LDFLAGS required to find these +- override LDFLAGS += -lssl -lcrypto -lstdc++ +-else +- # WITH_WOLFSSL=1 enables WolfSSL 4.2.0 support (mutually exclusive with OpenSSL) +- ifeq ($(WITH_WOLFSSL),1) +- # todo: change these +- override CFLAGS += -DLIBUS_USE_WOLFSSL -I/usr/local/include +- override LDFLAGS += -L/usr/local/lib -lwolfssl +- else +- override CFLAGS += -DLIBUS_NO_SSL +- endif ++COMMON_FLAGS += -DLIBUS_USE_OPENSSL ++LDFLAGS += -lssl -lcrypto -lstdc++ ++REQUIRES += libssl libcrypto + endif + + # WITH_LIBUV=1 builds with libuv as event-loop + ifeq ($(WITH_LIBUV),1) +- override CFLAGS += -DLIBUS_USE_LIBUV +- override LDFLAGS += -luv ++COMMON_FLAGS += -DLIBUS_USE_LIBUV ++REQUIRES += libuv + endif + +-# WITH_GCD=1 builds with libdispatch as event-loop +-ifeq ($(WITH_GCD),1) +- override CFLAGS += -DLIBUS_USE_GCD +- override LDFLAGS += -framework CoreFoundation +-endif ++CFLAGS += -std=c11 $(COMMON_FLAGS) ++CXXFLAGS += -std=c++17 $(COMMON_FLAGS) + +-# WITH_ASAN builds with sanitizers +-ifeq ($(WITH_ASAN),1) +- override CFLAGS += -fsanitize=address -g +- override LDFLAGS += -fsanitize=address +-endif +- +-override CFLAGS += -std=c11 -Isrc +-override LDFLAGS += uSockets.a +- +-# By default we build the uSockets.a static library + default: +- rm -f *.o +- $(CC) $(CFLAGS) -flto -O3 -c src/*.c src/eventing/*.c src/crypto/*.c +-# For now we do rely on C++17 for OpenSSL support but we will be porting this work to C11 ++ $(CC) $(CFLAGS) -fPIC -c src/*.c src/eventing/*.c src/crypto/*.c + ifeq ($(WITH_OPENSSL),1) +- $(CXX) $(CXXFLAGS) -std=c++17 -flto -O3 -c src/crypto/*.cpp ++ $(CXX) $(CXXFLAGS) -fPIC -c src/crypto/*.cpp + endif +- $(AR) rvs uSockets.a *.o +- +-# Builds all examples +-.PHONY: examples +-examples: default +- for f in examples/*.c; do $(CC) -flto -O3 $(CFLAGS) -o $$(basename "$$f" ".c") "$$f" $(LDFLAGS); done +- +-swift_examples: +- swiftc -O -I . examples/swift_http_server/main.swift uSockets.a -o swift_http_server ++ $(AR) rvs libusockets.a *.o ++ $(CC) -shared -o $(LIBTARGET) *.o -Wl,-soname,$(LIBTARGET) `$(PKG_CONFIG) --libs $(REQUIRES)` $(LDFLAGS) ++ sed -e "s:@PREFIX@:$(prefix):" -e "s:@REQUIRES@:$(REQUIRES):" \ ++ -e "s:@LIB@:$(LIB):" -e "s:@VERSION@:$(VERSION):" libusockets.pc.in > libusockets.pc ++ ++install: ++ install -d "$(DESTDIR)$(libdir)/pkgconfig" "$(DESTDIR)$(includedir)" ++ install -m 644 src/libusockets.h "$(DESTDIR)$(includedir)/" ++ install -m 755 $(LIBTARGET) "$(DESTDIR)$(libdir)" ++ ln -sf $(LIBTARGET) "$(DESTDIR)$(libdir)/libusockets.so" ++ install -m 755 libusockets.a "$(DESTDIR)$(libdir)/" ++ install -m 644 libusockets.pc "$(DESTDIR)$(libdir)/pkgconfig/" + + clean: + rm -f *.o + rm -f *.a ++ rm -f *.so + rm -rf .certs ++ rm -f libusockets.pc ++ ++.PHONY: default install clean +diff --git a/libusockets.pc.in b/libusockets.pc.in +new file mode 100644 +index 0000000..b818020 +--- /dev/null ++++ b/libusockets.pc.in +@@ -0,0 +1,12 @@ ++prefix=@PREFIX@ ++libdir=${prefix}/@LIB@ ++includedir=${prefix}/include ++ ++Name: uSockets ++Version: @VERSION@ ++Description: eventing, networking and crypto for async applications. ++URL: https://github.com/uNetworking/uSockets ++ ++Cflags: -I${includedir} ++Libs: -L${libdir} -lusockets ++Requires.private: @REQUIRES@ diff --git a/net-libs/usockets/usockets-9999.ebuild b/net-libs/usockets/usockets-0.7.1.ebuild similarity index 80% copy from net-libs/usockets/usockets-9999.ebuild copy to net-libs/usockets/usockets-0.7.1.ebuild index 37f78076..10ce0fdd 100644 --- a/net-libs/usockets/usockets-9999.ebuild +++ b/net-libs/usockets/usockets-0.7.1.ebuild @@ -12,10 +12,9 @@ if [[ ${PV} == 9999 ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/uNetworking/uSockets.git" else - COMMIT=45a70140b191e74c66301e5fefdacbd298b8c518 - SRC_URI="https://github.com/uNetworking/uSockets/archive/${COMMIT}.tar.gz -> ${P}.tar.gz" + SRC_URI="https://github.com/uNetworking/uSockets/archive/v${PV}.tar.gz -> ${P}.tar.gz" KEYWORDS="~amd64 ~arm64 ~x86" - S="${WORKDIR}/uSockets-${COMMIT}" + S="${WORKDIR}/uSockets-${PV}" fi LICENSE="Apache-2.0" @@ -29,7 +28,7 @@ DEPEND=" RDEPEND="${DEPEND}" PATCHES=( - "${FILESDIR}/${PN}-0.6.0-Makefile.patch" + "${FILESDIR}/${PN}-0.7.1-Makefile.patch" ) src_configure() { diff --git a/net-libs/usockets/usockets-9999.ebuild b/net-libs/usockets/usockets-9999.ebuild index 37f78076..10ce0fdd 100644 --- a/net-libs/usockets/usockets-9999.ebuild +++ b/net-libs/usockets/usockets-9999.ebuild @@ -12,10 +12,9 @@ if [[ ${PV} == 9999 ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/uNetworking/uSockets.git" else - COMMIT=45a70140b191e74c66301e5fefdacbd298b8c518 - SRC_URI="https://github.com/uNetworking/uSockets/archive/${COMMIT}.tar.gz -> ${P}.tar.gz" + SRC_URI="https://github.com/uNetworking/uSockets/archive/v${PV}.tar.gz -> ${P}.tar.gz" KEYWORDS="~amd64 ~arm64 ~x86" - S="${WORKDIR}/uSockets-${COMMIT}" + S="${WORKDIR}/uSockets-${PV}" fi LICENSE="Apache-2.0" @@ -29,7 +28,7 @@ DEPEND=" RDEPEND="${DEPEND}" PATCHES=( - "${FILESDIR}/${PN}-0.6.0-Makefile.patch" + "${FILESDIR}/${PN}-0.7.1-Makefile.patch" ) src_configure() {