From: Andrew Dunstan Date: Fri, 25 Nov 2022 20:28:38 +0000 (-0500) Subject: Allow building with MSVC and Strawberry perl X-Git-Tag: REL_11_19~40 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ae7c5121307d5c8b92b4e0ac63ec2e8635d8c076;p=thirdparty%2Fpostgresql.git Allow building with MSVC and Strawberry perl Strawberry uses __builtin_expect which Visual C doesn't have. For this case define it as a noop. Solution taken from vim sources. Backpatch to all live branches --- diff --git a/src/pl/plperl/plperl.h b/src/pl/plperl/plperl.h index 16186fc5293..f71119b82b3 100644 --- a/src/pl/plperl/plperl.h +++ b/src/pl/plperl/plperl.h @@ -41,6 +41,8 @@ */ #ifdef _MSC_VER #define __inline__ inline +/* Work around for using MSVC and Strawberry Perl >= 5.30. */ +#define __builtin_expect(expr, val) (expr) #endif /*