{"thread":{"id":"63597","subject":"[PATCH] config.mak.uname: update settings for Solaris 11","startedAt":"2025-06-07T02:35:40Z","lastAt":"2025-06-07T17:31:43Z","messageCount":3,"participants":["Brad Smith","Jonathan Nieder","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"519882","messageId":"aEOlc_PV7ZngUdj0@humpty.home.comstyle.com","threadId":"63597","inReplyTo":null,"subject":"[PATCH] config.mak.uname: update settings for Solaris 11","fromName":"Brad Smith","fromEmail":"brad@comstyle.com","sentAt":"2025-06-07T02:35:31Z","receivedAt":"2025-06-07T02:35:40Z","isPatch":true,"sender":{"key":"brad@comstyle.com","avatar":"https://avatars.githubusercontent.com/u/1129902?v=4"},"body":"Solaris 11.0 and newer have mkdtemp(), memmem(), strcasestr()\nand strtoumax().\n\nSigned-off-by: Brad Smith <brad@comstyle.com>\n---\n config.mak.uname | 28 +++++++++++++++++++++++++---\n 1 file changed, 25 insertions(+), 3 deletions(-)\n\ndiff --git a/config.mak.uname b/config.mak.uname\nindex 5a0b4200c3..1e933ead1e 100644\n--- a/config.mak.uname\n+++ b/config.mak.uname\n@@ -190,9 +190,6 @@ ifeq ($(uname_S),SunOS)\n \tSHELL_PATH = /bin/bash\n \tSANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin\n \tHAVE_ALLOCA_H = YesPlease\n-\tNO_STRCASESTR = YesPlease\n-\tNO_MEMMEM = YesPlease\n-\tNO_MKDTEMP = YesPlease\n \tNO_REGEX = YesPlease\n \tNO_MSGFMT_EXTENDED_OPTIONS = YesPlease\n \tHAVE_DEV_TTY = YesPlease\n@@ -202,7 +199,10 @@ ifeq ($(uname_S),SunOS)\n \t\tNO_IPV6 = YesPlease\n \t\tNO_SOCKADDR_STORAGE = YesPlease\n \t\tNO_UNSETENV = YesPlease\n+\t\tNO_MKDTEMP = YesPlease\n+\t\tNO_MEMMEM = YesPlease\n \t\tNO_SETENV = YesPlease\n+\t\tNO_STRCASESTR = YesPlease\n \t\tNO_STRLCPY = YesPlease\n \t\tNO_STRTOUMAX = YesPlease\n \t\tGIT_TEST_CMP = cmp\n@@ -212,23 +212,45 @@ ifeq ($(uname_S),SunOS)\n \t\tNO_IPV6 = YesPlease\n \t\tNO_SOCKADDR_STORAGE = YesPlease\n \t\tNO_UNSETENV = YesPlease\n+\t\tNO_MKDTEMP = YesPlease\n+\t\tNO_MEMMEM = YesPlease\n \t\tNO_SETENV = YesPlease\n+\t\tNO_STRCASESTR = YesPlease\n \t\tNO_STRLCPY = YesPlease\n \t\tNO_STRTOUMAX = YesPlease\n \t\tGIT_TEST_CMP = cmp\n         endif\n         ifeq ($(uname_R),5.8)\n \t\tNO_UNSETENV = YesPlease\n+\t\tNO_MKDTEMP = YesPlease\n+\t\tNO_MEMMEM = YesPlease\n \t\tNO_SETENV = YesPlease\n+\t\tNO_STRCASESTR = YesPlease\n \t\tNO_STRTOUMAX = YesPlease\n \t\tGIT_TEST_CMP = cmp\n         endif\n         ifeq ($(uname_R),5.9)\n \t\tNO_UNSETENV = YesPlease\n+\t\tNO_MKDTEMP = YesPlease\n+\t\tNO_MEMMEM = YesPlease\n \t\tNO_SETENV = YesPlease\n+\t\tNO_STRCASESTR = YesPlease\n \t\tNO_STRTOUMAX = YesPlease\n \t\tGIT_TEST_CMP = cmp\n         endif\n+        ifeq ($(uname_R),5.10)\n+\t\tNO_UNSETENV = YesPlease\n+\t\tNO_MKDTEMP = YesPlease\n+\t\tNO_MEMMEM = YesPlease\n+\t\tNO_SETENV = YesPlease\n+\t\tNO_STRCASESTR = YesPlease\n+\t\tGIT_TEST_CMP = cmp\n+        endif\n+        ifeq ($(uname_R),5.11)\n+\t\tNO_UNSETENV = YesPlease\n+\t\tNO_SETENV = YesPlease\n+\t\tGIT_TEST_CMP = cmp\n+        endif\n \tINSTALL = /usr/ucb/install\n \tTAR = gtar\n \tBASIC_CFLAGS += -D__EXTENSIONS__ -D__sun__\n-- \n2.49.0\n\n"},{"id":"519885","messageId":"aEP7kpQIHZx94eg6@google.com","threadId":"63597","inReplyTo":"aEOlc_PV7ZngUdj0@humpty.home.comstyle.com","subject":"Re: [PATCH] config.mak.uname: update settings for Solaris 11","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2025-06-07T08:42:58Z","receivedAt":"2025-06-07T08:43:02Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Brad Smith wrote:\n\n> Solaris 11.0 and newer have mkdtemp(), memmem(), strcasestr()\n> and strtoumax().\n>\n> Signed-off-by: Brad Smith <brad@comstyle.com>\n> ---\n>  config.mak.uname | 28 +++++++++++++++++++++++++---\n>  1 file changed, 25 insertions(+), 3 deletions(-)\n\nThanks!  That's from more than 10 years ago, so seems very reasonable\nto rely on.  I assume this is tested :), so lgtm.\n\nReviewed-by: Jonathan Nieder <jrnieder@gmail.com>\n\n[...]\n> --- a/config.mak.uname\n> +++ b/config.mak.uname\n> @@ -190,9 +190,6 @@ ifeq ($(uname_S),SunOS)\n>  \tSHELL_PATH = /bin/bash\n>  \tSANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin\n>  \tHAVE_ALLOCA_H = YesPlease\n> -\tNO_STRCASESTR = YesPlease\n> -\tNO_MEMMEM = YesPlease\n> -\tNO_MKDTEMP = YesPlease\n>  \tNO_REGEX = YesPlease\n>  \tNO_MSGFMT_EXTENDED_OPTIONS = YesPlease\n>  \tHAVE_DEV_TTY = YesPlease\n> @@ -202,7 +199,10 @@ ifeq ($(uname_S),SunOS)\n>  \t\tNO_IPV6 = YesPlease\n>  \t\tNO_SOCKADDR_STORAGE = YesPlease\n>  \t\tNO_UNSETENV = YesPlease\n> +\t\tNO_MKDTEMP = YesPlease\n> +\t\tNO_MEMMEM = YesPlease\n>  \t\tNO_SETENV = YesPlease\n> +\t\tNO_STRCASESTR = YesPlease\n>  \t\tNO_STRLCPY = YesPlease\n>  \t\tNO_STRTOUMAX = YesPlease\n>  \t\tGIT_TEST_CMP = cmp\n> @@ -212,23 +212,45 @@ ifeq ($(uname_S),SunOS)\n>  \t\tNO_IPV6 = YesPlease\n>  \t\tNO_SOCKADDR_STORAGE = YesPlease\n>  \t\tNO_UNSETENV = YesPlease\n> +\t\tNO_MKDTEMP = YesPlease\n> +\t\tNO_MEMMEM = YesPlease\n>  \t\tNO_SETENV = YesPlease\n> +\t\tNO_STRCASESTR = YesPlease\n>  \t\tNO_STRLCPY = YesPlease\n>  \t\tNO_STRTOUMAX = YesPlease\n>  \t\tGIT_TEST_CMP = cmp\n>          endif\n>          ifeq ($(uname_R),5.8)\n>  \t\tNO_UNSETENV = YesPlease\n> +\t\tNO_MKDTEMP = YesPlease\n> +\t\tNO_MEMMEM = YesPlease\n>  \t\tNO_SETENV = YesPlease\n> +\t\tNO_STRCASESTR = YesPlease\n>  \t\tNO_STRTOUMAX = YesPlease\n>  \t\tGIT_TEST_CMP = cmp\n>          endif\n>          ifeq ($(uname_R),5.9)\n>  \t\tNO_UNSETENV = YesPlease\n> +\t\tNO_MKDTEMP = YesPlease\n> +\t\tNO_MEMMEM = YesPlease\n>  \t\tNO_SETENV = YesPlease\n> +\t\tNO_STRCASESTR = YesPlease\n>  \t\tNO_STRTOUMAX = YesPlease\n>  \t\tGIT_TEST_CMP = cmp\n>          endif\n> +        ifeq ($(uname_R),5.10)\n> +\t\tNO_UNSETENV = YesPlease\n> +\t\tNO_MKDTEMP = YesPlease\n> +\t\tNO_MEMMEM = YesPlease\n> +\t\tNO_SETENV = YesPlease\n> +\t\tNO_STRCASESTR = YesPlease\n> +\t\tGIT_TEST_CMP = cmp\n> +        endif\n> +        ifeq ($(uname_R),5.11)\n> +\t\tNO_UNSETENV = YesPlease\n> +\t\tNO_SETENV = YesPlease\n> +\t\tGIT_TEST_CMP = cmp\n> +        endif\n\nNot about this change: do we want to retire some of the cases for old\nversions at some point, or to collapse them so they can share more?\nSeems nice for maintainability.\n\nSincerely,\nJonathan\n"},{"id":"519893","messageId":"xmqqbjqzzceb.fsf@gitster.g","threadId":"63597","inReplyTo":"aEP7kpQIHZx94eg6@google.com","subject":"Re: [PATCH] config.mak.uname: update settings for Solaris 11","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2025-06-07T17:31:40Z","receivedAt":"2025-06-07T17:31:43Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan Nieder <jrnieder@gmail.com> writes:\n\n> Brad Smith wrote:\n>\n>> Solaris 11.0 and newer have mkdtemp(), memmem(), strcasestr()\n>> and strtoumax().\n>>\n>> Signed-off-by: Brad Smith <brad@comstyle.com>\n>> ---\n>>  config.mak.uname | 28 +++++++++++++++++++++++++---\n>>  1 file changed, 25 insertions(+), 3 deletions(-)\n>\n> Thanks!  That's from more than 10 years ago, so seems very reasonable\n> to rely on.  I assume this is tested :), so lgtm.\n\nOne thing I didn't check myself is if the new make directive lines\n(ifeq and endif) are indented with SPs, not HTs.  I heard that newer\ngnumake is pickier than before?\n\nTo truly test this you'd have to have access to 5.5 or older, 5.6,\n5.7, 5.8, 5.9, 5.10, and 5.11, unless we declare that it is good\nenough to eyeball and to see the set of variables for these existing\nreleases hasn't changed ;-)  At least it does not break 5.10 and 5.11\n\nThis patch is good, and I'll queue it as-is; thanks for writing and\nreviewing.\n\nOutside the theme of this patch, should we also attach good-until\ndate on each of these entries, with scheduled deprecation/removal\nfor old ones?  If [*] and [**] can be believed, 5.6 for example have\nmet its EOL in July 2006.\n\n[*] https://computernewb.com/wiki/Oracle_Solaris_End_of_Life_Date\n[**] https://en.wikipedia.org/wiki/Oracle_Solaris#Version_history\n\n>\n> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>\n>\n> [...]\n>> --- a/config.mak.uname\n>> +++ b/config.mak.uname\n>> @@ -190,9 +190,6 @@ ifeq ($(uname_S),SunOS)\n>>  \tSHELL_PATH = /bin/bash\n>>  \tSANE_TOOL_PATH = /usr/xpg6/bin:/usr/xpg4/bin\n>>  \tHAVE_ALLOCA_H = YesPlease\n> ...\n> Not about this change: do we want to retire some of the cases for old\n> versions at some point, or to collapse them so they can share more?\n> Seems nice for maintainability.\n\nHeh, I should have read to the end of your message.\n\nMarking for retirement is certainly a good idea.\n\nAs there are way too more stale entries than entries for supported\nreleases (which are only 5.10 and 5.11 if [*] can be believed),\nrestructuring to share more may not be, depending on how it is done.\nThe current one already says \"These are common to all releases\" and\nthen independently list additional variables for each and every\nrelease, so you need to look at only two lists to see which\nvariables are applicable to one single release.\n\nWe cannot change it to \"all releases should use these\", followed by\n\"if you are at or older than 5.10, additionally use these\", followed\nby \"if you are at or older than 5.9, additionally use these\", ...,\nas we may add or remove these variables as releases progress and\ngain features, which may lose NO_FROTZ that used to signal the lack\nof frotz feature, or may gain HAVE_NITFOL that signals the gain of\nnitfol feature, in a newer release.\n\nThe current arrangement allows us to get rid the support for a\nsingle release fairly safely by just removing its release-specific\naddition part---if it makes some variables in release-specific\naddition part shared across all releases, like NO_UNSETENV and\nNO_SETENV already are, the result may be redundant and more verbose\nthan it necessarily is, but cleaning up to move these ones to common\nsection can be done independently from such a removal.\n\nAnd the same argument can be made when you add a new release, like\nthis patch does, to separate the addition of a support and cleaning\nup.  It is clear from the patch text that we are losing three from\nthe commonly shared part and adding them to all the existing ones,\nplus writing release specific additions for 5.10 and 5.11.\n\nAfter the dust settles from this patch, we may want to see if there\nare ones like NO_SETENV/NO_UNSETENV/GIT_TEST_CMP that can be shared\nacross all releases and move them to the commonly shared part as a\nfollow-up patch.\n\nThanks.\n"}]}