Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ogAhs-0000CU-Au for pgsql-hackers@arkaria.postgresql.org; Wed, 05 Oct 2022 20:09:28 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ogAhr-0001AO-7Q for pgsql-hackers@arkaria.postgresql.org; Wed, 05 Oct 2022 20:09:27 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ogAhq-0001AF-Uv for pgsql-hackers@lists.postgresql.org; Wed, 05 Oct 2022 20:09:26 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ogAho-0002vz-O6 for pgsql-hackers@postgresql.org; Wed, 05 Oct 2022 20:09:25 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 295K9E162550387; Wed, 5 Oct 2022 16:09:14 -0400 From: Tom Lane To: Andres Freund cc: pgsql-hackers@postgresql.org, Thomas Munro , Justin Pryzby , Michael Paquier , Peter Eisentraut Subject: Re: meson: Add support for building with precompiled headers In-reply-to: <20221005190829.lda7ttalh4mzrvf4@awork3.anarazel.de> References: <20221005190829.lda7ttalh4mzrvf4@awork3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Wed, 05 Oct 2022 12:08:29 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2550385.1665000554.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Wed, 05 Oct 2022 16:09:14 -0400 Message-ID: <2550386.1665000554@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andres Freund writes: > When using precompiled headers we cannot override macros in system heade= rs > from within .c files, as headers are already processed before the #defin= e in > the C file is reached. > A few files #define FD_SETSIZE 1024 on windows, as the default is only 6= 4. I > am hesitant to change FD_SETSIZE globally on windows, due to > src/backend/port/win32/socket.c using it to size on-stack arrays. Instea= d add > -DFD_SETSIZE=3D1024 when building the specific targets needing it. Color me confused, but how does it work to #define that from the command line if it can't be overridden from within the program? regards, tom lane