Re: BUG #18995: Building with GCC 14 fails: incompatible pointer struct pam_message

Andrew Watkins <awatkins1966@gmail.com>

From: Andrew Watkins <awatkins1966@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@lists.postgresql.org
Date: 2025-07-23T15:31:10Z
Lists: pgsql-bugs

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Fix build breakage on Solaris-alikes with late-model GCC.

>
>
>
> On my Linux box I find this in /usr/include/security/_pam_types.h:
>
> struct pam_conv {
>     int (*conv)(int num_msg, const struct pam_message **msg,
>                 struct pam_response **resp, void *appdata_ptr);
>     void *appdata_ptr;
> };


 You are right Solaris is missing "const"

struct pam_conv {
        int (*conv)(int, struct pam_message **, struct pam_response **,
void *);
        void *appdata_ptr;
};

Sorry, for digging up an old problem . I did some searching of the archive
but never found that link going back to 2007.

Now with your pointer I can see Oracle Solaris get over this problem by
patching source code of software. Guess they can't afford to fix
the  pam_appl.h file.

Thanks
Andrew