From nobody Sat Nov 18 20:22:56 2023 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SXlZS3fGpz51ZhT; Sat, 18 Nov 2023 20:22:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SXlZS30MSz4TtB; Sat, 18 Nov 2023 20:22:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700338976; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4onJ5Gt9rUDsRFwuJAUji5zQI0GvVyT8D8S644hSiuU=; b=pMMre5hm2bbXSSNiKr1GGisi1Jg+0KbDxlLcLZR0liVZ/Tnq/YsUvMX2JkznsCyjwMkUk6 fsLGWZFsGoq7z68niItb/3V+TXo5zhyYk5RVw08QqRtvnurpr+89cDN9/Zsom5dGLJ4b2k SXYYX/imbzy64BosSYza9etcSAcw/Vk1u9egIHq/K4xPHHzSf0C13JB1tcGAZGSOlI7E+m WNWlH7/pHI39jtjfqppgR8hdON3sgwcZTCKPDGm/upntMW1kIH0T5bz8wrH+bH9ln6y5pA Ko0eQUVQp9GLCk2XIgY/NKtepDMHH5+LqjMKSMNxBfYNERcFg8VnzFOLKhyeWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700338976; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4onJ5Gt9rUDsRFwuJAUji5zQI0GvVyT8D8S644hSiuU=; b=iypdTS+W2pvr8sgoxfYUTv/NqQj5KjmZ6NypBy3Ro7Hbvwb3KGddTQi7RUSuEQA82j/6um OKBD8XLdLYGOm4uMPB2+A5niDdQ+pdnWhWKEqtTO4nXeRtk56yISPVOY0pK9fb+aPuHqn+ vxcI6F33Dqs3ykMQSIQpVNEDw1k3vRGwmL+bUmNocd+sqF54suACQEtmHjq9ZFjkIMKnPR 8k31F4m6JD4CfXSANgKEAbHyYfetKOteITaNH0ZU8C4CFueS3ZtBd9+Hc+2kDKdxApYHnW xWcOaNYouip/P+Lepa3ENzLgp0loSdvrkIkH64yP/yV24fONYGuFHtQwFgKeZg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1700338976; a=rsa-sha256; cv=none; b=pbrnfbG9xzy6S9dr2gjPji9G7q+xJ2cWTnwTuWQffoxbwDM+1RI8oyH4WHRDutP3gc5Zkz cowvH8cruozmeiusygJwm/L3EmF3YZWOfSevPIa+Dyjp4BJjdSTVls4c36tB1TqqIze3Cw 7MXAOIcRg7l6+OFFn/a1C0a7H3Vt0rJgfsw977w0lWi4cyVSe+u+Gc/q+NRD5K94mjxicG /bZl30sqS8JrlfpnqhGDaV4ICzZUXaPi764vsUZTvZBIw5sfdTLYYXPxDVRlSxDjKkMXuq v0YuXIgoIcMfGpRhkiHC9ZmcbQs4f4QVWoG+aq104lynQrcFxHxvfGft+qkVDg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SXlZS1nTQzgJx; Sat, 18 Nov 2023 20:22:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 3AIKMuGV015929; Sat, 18 Nov 2023 20:22:56 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3AIKMuE7015926; Sat, 18 Nov 2023 20:22:56 GMT (envelope-from git) Date: Sat, 18 Nov 2023 20:22:56 GMT Message-Id: <202311182022.3AIKMuE7015926@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Robert Clausecker Subject: git: bd7b56ae1896 - main - devel/kore: fix build on armv7 and clean up List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: fuz X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: bd7b56ae1896ca6c74df5ae31fee35efd107caa7 Auto-Submitted: auto-generated The branch main has been updated by fuz: URL: https://cgit.FreeBSD.org/ports/commit/?id=bd7b56ae1896ca6c74df5ae31fee35efd107caa7 commit bd7b56ae1896ca6c74df5ae31fee35efd107caa7 Author: Robert Clausecker AuthorDate: 2023-11-17 22:23:24 +0000 Commit: Robert Clausecker CommitDate: 2023-11-18 20:20:44 +0000 devel/kore: fix build on armv7 and clean up - fix a warning about a wrong formatting specifier - exorcise -Werror so future warnings do not break the build - as a result, simplify Makefile - switch to C11 to avoid some warnings - reinstate %%OPENSSLINC%% patch bits dropped in previous commit - patch in %%LOCALBASE%% correctly MFH: 2023Q4 --- devel/kore/Makefile | 21 ++++-------- devel/kore/files/patch-Makefile | 38 ++++++++++++++++++++-- devel/kore/files/patch-kodev_Makefile | 13 +++++--- devel/kore/files/patch-src_cli.c | 11 +++++++ devel/kore/files/patch-src_python.c | 11 +++++++ .../files/patch-tools_kore-serve_conf_build.conf | 10 ++++++ 6 files changed, 83 insertions(+), 21 deletions(-) diff --git a/devel/kore/Makefile b/devel/kore/Makefile index 33de8c0d8d8c..40fd005128fe 100644 --- a/devel/kore/Makefile +++ b/devel/kore/Makefile @@ -1,5 +1,6 @@ PORTNAME= kore -PORTVERSION= 4.2.3 +DISTVERSION= 4.2.3 +PORTREVISON= 1 CATEGORIES= devel www MASTER_SITES= https://kore.io/releases/ @@ -16,9 +17,7 @@ BROKEN_SSL_REASON= Requires OpenSSL 3.0.0 deprecated RSA_* routines USES= compiler:c11 gmake ssl MAKE_ARGS= OPENSSL_PATH=${OPENSSLBASE} -CFLAGS+= ${CFLAGS_${CHOSEN_COMPILER_TYPE}} -# 12.0 + -pedantic -CFLAGS_clang= -Wno-error=c11-extensions +CFLAGS+= -std=c11 PORTEXAMPLES= * @@ -49,17 +48,9 @@ PYTHON_BINARY_ALIAS= python3-config=${PYTHON_CMD}-config TASKS_MAKE_ARGS= TASKS=1 TLS_MAKE_ARGS_OFF= NOTLS=1 -.include - -.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 160 -CFLAGS+= -Wno-error=deprecated-declarations -Wno-error=incompatible-pointer-types-discards-qualifiers -.endif - -post-patch: -.if ${LOCALBASE} != /usr/local - @${REINPLACE_CMD} 's|/usr/local/|${LOCALBASE}/|g' \ +pre-configure: + @${REINPLACE_CMD} 's|%%LOCALBASE%%|${LOCALBASE}/|g' \ ${WRKSRC}/Makefile -.endif @${REINPLACE_CMD} 's|%%OPENSSLINC%%|${OPENSSLINC}|g' \ ${WRKSRC}/src/cli.c @@ -71,4 +62,4 @@ post-install-EXAMPLES-on: @cd ${WRKSRC}/examples && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} @cd ${WRKSRC}/conf && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} -.include +.include diff --git a/devel/kore/files/patch-Makefile b/devel/kore/files/patch-Makefile index 2413aba71126..6ff3989fb674 100644 --- a/devel/kore/files/patch-Makefile +++ b/devel/kore/files/patch-Makefile @@ -1,6 +1,18 @@ ---- Makefile.orig 2020-09-08 19:35:30 UTC +--- Makefile.orig 2022-08-22 11:18:44 UTC +++ Makefile -@@ -48,12 +48,6 @@ ifneq ("$(DEBUG)", "") +@@ -31,9 +31,9 @@ S_SRC+= src/tls_$(TLS_BACKEND).c + FEATURES= + FEATURES_INC= + +-CFLAGS+=-Wall -Werror -Wstrict-prototypes -Wmissing-prototypes ++CFLAGS+=-Wall -Wstrict-prototypes -Wmissing-prototypes + CFLAGS+=-Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual +-CFLAGS+=-Wsign-compare -Iinclude/kore -I$(OBJDIR) -std=c99 -pedantic ++CFLAGS+=-Wsign-compare -Iinclude/kore -I$(OBJDIR) -pedantic + CFLAGS+=-Wtype-limits -fno-common + CFLAGS+=-DPREFIX='"$(PREFIX)"' -fstack-protector-all + +@@ -66,12 +66,6 @@ ifneq ("$(DEBUG)", "") FEATURES+=-DKORE_DEBUG endif @@ -13,3 +25,25 @@ ifneq ("$(NOSENDFILE)", "") CFLAGS+=-DKORE_NO_SENDFILE endif +@@ -120,8 +114,8 @@ endif + + OSNAME=$(shell uname -s | sed -e 's/[-_].*//g' | tr A-Z a-z) + ifeq ("$(OSNAME)", "freebsd") +- KORE_CURL_LIB=-L/usr/local/lib -lcurl +- KORE_CURL_INC=-I/usr/local/include ++ KORE_CURL_LIB=-L%%LOCALBASE%%/lib -lcurl ++ KORE_CURL_INC=-I%%LOCALBASE%%/include + endif + + ifneq ("$(ACME)", "") +@@ -161,8 +155,8 @@ else ifeq ("$(OSNAME)", "linux") + else + S_SRC+=src/bsd.c + ifneq ("$(JSONRPC)", "") +- CFLAGS+=-I/usr/local/include +- LDFLAGS+=-L/usr/local/lib ++ CFLAGS+=-I%%LOCALBASE%%/include ++ LDFLAGS+=-L%%LOCALBASE%%/lib + endif + endif + diff --git a/devel/kore/files/patch-kodev_Makefile b/devel/kore/files/patch-kodev_Makefile index 533af6f02cbd..baa8e5315099 100644 --- a/devel/kore/files/patch-kodev_Makefile +++ b/devel/kore/files/patch-kodev_Makefile @@ -1,9 +1,13 @@ ---- kodev/Makefile.orig 2020-09-08 19:35:30 UTC +--- kodev/Makefile.orig 2022-08-22 11:18:44 UTC +++ kodev/Makefile -@@ -12,14 +12,8 @@ S_SRC= ../src/cli.c - CFLAGS+=-Wall -Werror -Wstrict-prototypes -Wmissing-prototypes +@@ -9,17 +9,11 @@ INSTALL_DIR=$(PREFIX)/bin + + S_SRC= ../src/cli.c + +-CFLAGS+=-Wall -Werror -Wstrict-prototypes -Wmissing-prototypes ++CFLAGS+=-Wall -Wstrict-prototypes -Wmissing-prototypes CFLAGS+=-Wmissing-declarations -Wshadow -Wpointer-arith -Wcast-qual - CFLAGS+=-Wsign-compare -Iincludes -std=c99 -pedantic +-CFLAGS+=-Wsign-compare -Iincludes -std=c99 -pedantic -CFLAGS+=-DPREFIX='"$(PREFIX)"' -LDFLAGS=-lcrypto - @@ -12,6 +16,7 @@ -else - CFLAGS+=-O2 -endif ++CFLAGS+=-Wsign-compare -Iincludes -pedantic +CFLAGS+=-DPREFIX='"$(PREFIX)"' -I$(OPENSSL_PATH)/include +LDFLAGS+=-L$(OPENSSL_PATH)/lib -lcrypto diff --git a/devel/kore/files/patch-src_cli.c b/devel/kore/files/patch-src_cli.c new file mode 100644 index 000000000000..fb0ba4393640 --- /dev/null +++ b/devel/kore/files/patch-src_cli.c @@ -0,0 +1,11 @@ +--- src/cli.c.orig 2022-08-22 11:18:44 UTC ++++ src/cli.c +@@ -867,6 +867,8 @@ cli_ldflags(int argc, char **argv) + cli_kore_load_file("linker", NULL, &p, &len); + printf("%.*s ", (int)len, p); + ++ printf("-I%%OPENSSLINC%% "); ++ + #if defined(__MACH__) + printf("-dynamiclib -undefined suppress -flat_namespace "); + #else diff --git a/devel/kore/files/patch-src_python.c b/devel/kore/files/patch-src_python.c new file mode 100644 index 000000000000..1df8f209a100 --- /dev/null +++ b/devel/kore/files/patch-src_python.c @@ -0,0 +1,11 @@ +--- src/python.c.orig 2023-11-17 22:08:08 UTC ++++ src/python.c +@@ -4828,7 +4828,7 @@ pyhttp_iterobj_next(struct pyhttp_iterobj *iterobj) + } + + kore_buf_reset(&iterobj->buf); +- kore_buf_appendf(&iterobj->buf, "%lx\r\n", length); ++ kore_buf_appendf(&iterobj->buf, "%zx\r\n", length); + kore_buf_append(&iterobj->buf, ptr, length); + kore_buf_appendf(&iterobj->buf, "\r\n"); + diff --git a/devel/kore/files/patch-tools_kore-serve_conf_build.conf b/devel/kore/files/patch-tools_kore-serve_conf_build.conf new file mode 100644 index 000000000000..be1d1dc8c9a0 --- /dev/null +++ b/devel/kore/files/patch-tools_kore-serve_conf_build.conf @@ -0,0 +1,10 @@ +--- tools/kore-serve/conf/build.conf.orig 2022-08-22 11:18:44 UTC ++++ tools/kore-serve/conf/build.conf +@@ -2,7 +2,6 @@ single_binary=yes + kore_source=../../ + kore_flavor=NOTLS=1 + +-cflags=-std=c99 -Werror + cflags=-Wall -Wmissing-declarations -Wshadow + cflags=-Wstrict-prototypes -Wmissing-prototypes + cflags=-Wpointer-arith -Wcast-qual -Wsign-compare