{"thread":{"id":"64633","subject":"[PATCH v0 2/3] Makefile: Make all darwin into config.mak.uname","startedAt":"2025-12-15T20:45:31Z","lastAt":"2025-12-16T18:53:21Z","messageCount":2,"participants":["tboegi@web.de","René Scharfe"],"isPatch":true,"patchVersion":0,"patchTotal":3},"messages":[{"id":"532203","messageId":"20251215204522.1946504-1-tboegi@web.de","threadId":"64633","inReplyTo":null,"subject":"[PATCH v0 2/3] Makefile: Make all darwin into config.mak.uname","fromName":"","fromEmail":"tboegi@web.de","sentAt":"2025-12-15T20:45:22Z","receivedAt":"2025-12-15T20:45:31Z","isPatch":true,"sender":{"key":"tboegi@web.de","avatar":"https://avatars.githubusercontent.com/u/7138363?v=4"},"body":"From: Torsten Bögershausen <tboegi@web.de>\n\nMove all the Darwin stuff from Makefile into config.mak.uname,\nwe need it there in the next commit.\n\nSigned-off-by: Torsten Bögershausen <tboegi@web.de>\n---\n Makefile         | 21 ---------------------\n config.mak.uname | 18 ++++++++++++++++++\n 2 files changed, 18 insertions(+), 21 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 6de036e4e2..2d666c26e4 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -1672,27 +1672,6 @@ ifneq (,$(SOCKLEN_T))\n \tBASIC_CFLAGS += -Dsocklen_t=$(SOCKLEN_T)\n endif\n \n-ifeq ($(uname_S),Darwin)\n-        ifndef NO_FINK\n-                ifeq ($(shell test -d /sw/lib && echo y),y)\n-\t\t\tBASIC_CFLAGS += -I/sw/include\n-\t\t\tBASIC_LDFLAGS += -L/sw/lib\n-                endif\n-        endif\n-        ifndef NO_DARWIN_PORTS\n-                ifeq ($(shell test -d /opt/local/lib && echo y),y)\n-\t\t\tBASIC_CFLAGS += -I/opt/local/include\n-\t\t\tBASIC_LDFLAGS += -L/opt/local/lib\n-                endif\n-        endif\n-        ifndef NO_APPLE_COMMON_CRYPTO\n-\t\tNO_OPENSSL = YesPlease\n-\t\tAPPLE_COMMON_CRYPTO = YesPlease\n-\t\tCOMPAT_CFLAGS += -DAPPLE_COMMON_CRYPTO\n-        endif\n-\tPTHREAD_LIBS =\n-endif\n-\n ifndef NO_HOMEBREW\n \tifdef HOMEBREW_PREFIX\n \t\tBASIC_CFLAGS += -I$(HOMEBREW_PREFIX)/include\ndiff --git a/config.mak.uname b/config.mak.uname\nindex a926943141..44252dabcc 100644\n--- a/config.mak.uname\n+++ b/config.mak.uname\n@@ -189,6 +189,24 @@ ifeq ($(uname_S),Darwin)\n         endif\n \n \tBASIC_LDFLAGS += -framework CoreServices\n+\tifndef NO_FINK\n+\t\tifeq ($(shell test -d /sw/lib && echo y),y)\n+\t\t\tBASIC_CFLAGS += -I/sw/include\n+\t\t\tBASIC_LDFLAGS += -L/sw/lib\n+\t\tendif\n+\tendif\n+\tifndef NO_DARWIN_PORTS\n+\t\tifeq ($(shell test -d /opt/local/lib && echo y),y)\n+\t\t\tBASIC_CFLAGS += -I/opt/local/include\n+\t\t\tBASIC_LDFLAGS += -L/opt/local/lib\n+\t\tendif\n+\tendif\n+\tifndef NO_APPLE_COMMON_CRYPTO\n+\t\tNO_OPENSSL = YesPlease\n+\t\tAPPLE_COMMON_CRYPTO = YesPlease\n+\t\tCOMPAT_CFLAGS += -DAPPLE_COMMON_CRYPTO\n+\tendif\n+\tPTHREAD_LIBS =\n endif\n ifeq ($(uname_S),SunOS)\n \tNEEDS_SOCKET = YesPlease\n-- \n2.50.0.rc0.46.g7014b55638.dirty\n\n"},{"id":"532298","messageId":"4e1e1e07-f16e-4e6f-ba1f-325124fbe6db@web.de","threadId":"64633","inReplyTo":"20251215204522.1946504-1-tboegi@web.de","subject":"Re: [PATCH v0 2/3] Makefile: Make all darwin into config.mak.uname","fromName":"René Scharfe","fromEmail":"l.s.r@web.de","sentAt":"2025-12-16T18:53:19Z","receivedAt":"2025-12-16T18:53:21Z","isPatch":true,"sender":{"key":"l.s.r@web.de","avatar":"https://avatars.githubusercontent.com/u/26122331?v=4"},"body":"On 12/15/25 9:45 PM, tboegi@web.de wrote:\n> From: Torsten Bögershausen <tboegi@web.de>\n> \n> Move all the Darwin stuff from Makefile into config.mak.uname,\n> we need it there in the next commit.\n> \n> Signed-off-by: Torsten Bögershausen <tboegi@web.de>\n> ---\n>  Makefile         | 21 ---------------------\n>  config.mak.uname | 18 ++++++++++++++++++\n>  2 files changed, 18 insertions(+), 21 deletions(-)\n> \n> diff --git a/Makefile b/Makefile\n> index 6de036e4e2..2d666c26e4 100644\n> --- a/Makefile\n> +++ b/Makefile\n> @@ -1672,27 +1672,6 @@ ifneq (,$(SOCKLEN_T))\n>  \tBASIC_CFLAGS += -Dsocklen_t=$(SOCKLEN_T)\n>  endif\n>  \n> -ifeq ($(uname_S),Darwin)\n> -        ifndef NO_FINK\n> -                ifeq ($(shell test -d /sw/lib && echo y),y)\n> -\t\t\tBASIC_CFLAGS += -I/sw/include\n> -\t\t\tBASIC_LDFLAGS += -L/sw/lib\n> -                endif\n> -        endif\n> -        ifndef NO_DARWIN_PORTS\n> -                ifeq ($(shell test -d /opt/local/lib && echo y),y)\n> -\t\t\tBASIC_CFLAGS += -I/opt/local/include\n> -\t\t\tBASIC_LDFLAGS += -L/opt/local/lib\n> -                endif\n> -        endif\n> -        ifndef NO_APPLE_COMMON_CRYPTO\n> -\t\tNO_OPENSSL = YesPlease\n> -\t\tAPPLE_COMMON_CRYPTO = YesPlease\n> -\t\tCOMPAT_CFLAGS += -DAPPLE_COMMON_CRYPTO\n> -        endif\n> -\tPTHREAD_LIBS =\n> -endif\n> -\n>  ifndef NO_HOMEBREW\n>  \tifdef HOMEBREW_PREFIX\n>  \t\tBASIC_CFLAGS += -I$(HOMEBREW_PREFIX)/include\n> diff --git a/config.mak.uname b/config.mak.uname\n> index a926943141..44252dabcc 100644\n> --- a/config.mak.uname\n> +++ b/config.mak.uname\n> @@ -189,6 +189,24 @@ ifeq ($(uname_S),Darwin)\n>          endif\n>  \n>  \tBASIC_LDFLAGS += -framework CoreServices\n> +\tifndef NO_FINK\n> +\t\tifeq ($(shell test -d /sw/lib && echo y),y)\n> +\t\t\tBASIC_CFLAGS += -I/sw/include\n> +\t\t\tBASIC_LDFLAGS += -L/sw/lib\n> +\t\tendif\n> +\tendif\n> +\tifndef NO_DARWIN_PORTS\n> +\t\tifeq ($(shell test -d /opt/local/lib && echo y),y)\n> +\t\t\tBASIC_CFLAGS += -I/opt/local/include\n> +\t\t\tBASIC_LDFLAGS += -L/opt/local/lib\n> +\t\tendif\n> +\tendif\n> +\tifndef NO_APPLE_COMMON_CRYPTO\n> +\t\tNO_OPENSSL = YesPlease\n> +\t\tAPPLE_COMMON_CRYPTO = YesPlease\n> +\t\tCOMPAT_CFLAGS += -DAPPLE_COMMON_CRYPTO\n> +\tendif\n> +\tPTHREAD_LIBS =\n>  endif\n>  ifeq ($(uname_S),SunOS)\n>  \tNEEDS_SOCKET = YesPlease\n\nThis works if you set these variables on the make command line, but it\nwon't work when setting them in config.mak, which is the main place for\ncustom make variables.  That's because it's included last in Makefile:\n\ninclude config.mak.uname\n-include config.mak.autogen\n-include config.mak\n\nRené\n\n"}]}