From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05olkn2099.outbound.protection.outlook.com [40.92.91.99]) by sourceware.org (Postfix) with ESMTPS id EE8D33858C60 for ; Fri, 21 Jan 2022 10:08:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org EE8D33858C60 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=live.co.uk Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=live.co.uk ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XGck0/upPfnzGijVhoomWXnCri6TgzWLaFrSo7OQTx/vr6ETJURd3R2gcvM3mirKNyPhjkuiRH8nzgabMEmjt1omCOj/OQVEILHVamqTcCbS1y6OK8bXrEqCsEa2UZ28wz+5GJ8BODn9roaE0mThNMU7GWgW5Cc2XNFgFYDIZEt4bTp9JAHsAp+ZpZxviyZ84qkKNpLX2fj8SpHlVhUx2fujuJtuezVD/Pi44flALOWTBGhiuayQLySZH3Obj9Tp2vkj1aHon/fLZNZt0A1ISB8/k93gqeJY8GONkRbY2gS2vfOtwhJFK4k7NyfcXqWUf4EtrT2DquG/a7i/tuTazA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=FMWLAe7Kpb91GvvGMH+AG6yLQWJKOrlcCZjcmuB8ZnE=; b=VTfS9za05yX4QfB/OfjuSkd+DgxcOCXOcCpbKmS90bTOghX5q2ILoBJE1oeIkhdrK8WZRcLtnztk1qp3NhVIfcycI5HDodyCRLOA6IyaItUDpVj50iX2gMOp0RSSN2LPWdIGLbdKdIpr7bboke5ffYN8H4haGrs5bioruIERzCm7o9DQ0w523phWAByETYs094rDSn6ymg+1GRi0Y8hv03doFuGYBF6MnaNSLgXrWWS/ZtVD/TIr5aKOvOfkBwJzxd+B9TrLPIyoP+y7gjvEGn1oUzYu9qy91Tq41ltftInKODJMq0LEw+LGtDNF46qkx/f5G2NH0Uhr3iM6W336Gw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none Received: from DB3PR0202MB3561.eurprd02.prod.outlook.com (2603:10a6:8:8::22) by DBAPR02MB6087.eurprd02.prod.outlook.com (2603:10a6:10:179::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4909.8; Fri, 21 Jan 2022 10:08:52 +0000 Received: from DB3PR0202MB3561.eurprd02.prod.outlook.com ([fe80::d078:48d0:82c3:90ad]) by DB3PR0202MB3561.eurprd02.prod.outlook.com ([fe80::d078:48d0:82c3:90ad%5]) with mapi id 15.20.4909.012; Fri, 21 Jan 2022 10:08:52 +0000 To: "cygwin-apps@cygwin.com" References: From: Hamish McIntyre-Bhatty Subject: Re: Help needed with wxWidgets3.1 tests compilation error Message-ID: Date: Fri, 21 Jan 2022 10:08:49 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 8bit X-TMN: [YZyMfoNWitLPdZ0eCzUDHyQK+j13X9t6] X-ClientProxiedBy: LO2P123CA0106.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:139::21) To DB3PR0202MB3561.eurprd02.prod.outlook.com (2603:10a6:8:8::22) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5f2f252f-f0e6-4023-d172-08d9dcc60620 X-MS-TrafficTypeDiagnostic: DBAPR02MB6087:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: m6VfNmcbt39gcyyB7GuEkxtq/98MzBRwc11OOV7QWY0obpYKIfUSBEEG9GgsEv/8zSdJX85iJ68kTMJvKOxdwXJZrF+eU1FXOnFfnKaK3ASRTqmtDWIRYEKe+S+vqJXX7WFqLJ6ZFhMng0hyinX7ceAgS5yNs92qwzM1wG6TiAZWW93d0EQVRS6NpfGm4vhtFgbr4McB8xB9jPKzZ0w5mJlfl9O5KuqqSHe+q9+2T3swyWXOeSmnBHRtxm+EtrKiQPKaXK+ycLwWCRAdniQcGVjjtBZfkLt+w7Ae0SCn5PqTI5+6HzZd1PY5G+ugBs3XdYKxNWMmadNrIvl4xdzEVjG9i44d6uIpZa0brnhImPnznc9Ucd6K4FT3NBvJbUii8bRlgqBbarYKjqu0RBqWiWdgSchnatv1LGHwqCU34i1R0Q6N4Z3PUAOReuKzGH/nbyYgTEN9cn+jOYNjlIIt39Y0VyuJjCJPzDNNTsqDFtyw6/8qbJJhDUH+uLpZg//bI6nUmDRf7bsaZI2aeu231YMzk+GT89cnkURH0L6mmMu1vx+L+eP0/zGUxSgedWPcDU+jBfGDyXCwJrhHlOBDqw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?QmNtVlJoZ3VmUGNRaEM1UmhySjZoejRvdnNKN2JuMEx3TEprcFBCN3hhdEZ1?= =?utf-8?B?ZTgrVTNUUThoRStQcnVJMXN0V1hXRmFXUEFwcGpSQmpZMExZcmNxeVVMbVB1?= =?utf-8?B?R2QxRFN3VnN3MWdhMzkzbXptdkRMdzMwRlloaUZBZHlxU1hQUzU0NEFDLzRY?= =?utf-8?B?TG5GbVFSR3RoVmZlakcreDg2MXo4VVVuaTYvRlRaS0RVTWJjamtZbEhhN284?= =?utf-8?B?VUtrZ2drNHROUnR0M2RjOGVzZFArb0grLzVEcWx4eXNlNllTcXR3cy96OGQ3?= =?utf-8?B?bnh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RpeWhPOGwx?= =?utf-8?B?N3JrWUdxRjRwZncxbnM2R2pTQ3ZONC80RTA1MlV6ZksrRS9YSk5OVGJFa2lr?= =?utf-8?B?OTFQTlM4V1NTQnF0ZGF3eXB4SURmTm55dkNUVC9PcWFyL0EwQT09?= X-OriginatorOrg: sct-15-20-4755-11-msonline-outlook-ab7de.templateTenant X-MS-Exchange-CrossTenant-Network-Message-Id: 5f2f252f-f0e6-4023-d172-08d9dcc60620 X-MS-Exchange-CrossTenant-AuthSource: DB3PR0202MB3561.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jan 2022 10:08:52.0334 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAPR02MB6087 X-Spam-Status: No, score=-3027.8 required=5.0 tests=BAYES_00, BODY_8BITS, FORGED_MUA_MOZILLA, KAM_COUK, KAM_DMARC_STATUS, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: cygwin-apps@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Cygwin package maintainer discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Jan 2022 10:08:55 -0000 On 20/01/2022 20:38, Brian Inglis wrote: > On 2022-01-20 10:10, Hamish McIntyre-Bhatty wrote: >> I've been having trouble compiling the unit tests for >> wxWidgets3.1-3.1.5 on Cygwin. The same tests build just fine on my >> Linux Mint 20.3 install, however that is using GCC 9.3.0 instead of >> Cygwin's 11.2.0. >> >> Attached is the full build log, but I will also point out my ideas >> about particular issues here. >> >> Note: -Werror=format-security is used in the Makefile. I couldn't find >> exactly what this does, but I'm probably looking in the wrong place - >> the manpage. Perhaps the following could also be explained by >> differences from GCC 9 to 11? > > I check first as in `info GCC Wformat-security` should only care about > *printf string variables without using a separate format string. Ah okay, I guess that doesn't explain the -Werror=zero-as-null-pointer-constant errors later. I guess that might be a GCC default change. > >> The first is: >> >> In file included from /usr/include/unistd.h:4, >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/filefn.h:23, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/utils.h:20, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/cursor.h:75, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/event.h:22, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/evtloop.h:14, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/testprec.h:5, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/allheaders.cpp:433: >> >> /usr/include/sys/unistd.h:23:9: error: redundant redeclaration of ‘int >> chmod(const char*, mode_t)’ in same scope [-Werror=redundant-decls] >>     23 | int     chmod (const char *__path, mode_t __mode); >>        |         ^~~~~ >> In file included from /usr/include/sys/_default_fcntl.h:211, >>                   from /usr/include/sys/fcntl.h:3, >>                   from /usr/include/fcntl.h:12, >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/allheaders.cpp:83: >> >> /usr/include/sys/stat.h:137:9: note: previous declaration of ‘int >> chmod(const char*, mode_t)’ >>    137 | int     chmod (const char *__path, mode_t __mode ); >>        |         ^~~~~ >> >> This doesn't happen on my Linux Mint 20.3 (Ubuntu 20.04) host, so I'm >> assuming this is something to do with the standard library? >> >> Next is: >> >> In file included from /usr/include/unistd.h:4, >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/filefn.h:23, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/utils.h:20, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/cursor.h:75, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/event.h:22, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/include/wx/evtloop.h:14, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/testprec.h:5, >> >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/allheaders.cpp:433: >> >> /usr/include/sys/unistd.h:179:9: error: redundant redeclaration of >> ‘int pthread_atfork(void (*)(), void (*)(), void (*)())’ in same scope >> [-Werror=redundant-decls] >>    179 | int     pthread_atfork (void (*)(void), void (*)(void), void >> (*)(void)); >>        |         ^~~~~~~~~~~~~~ >> In file included from >> /usr/lib/gcc/x86_64-pc-cygwin/11/include/c++/x86_64-pc-cygwin/bits/gthr-default.h:35, >> >>                   from >> /usr/lib/gcc/x86_64-pc-cygwin/11/include/c++/x86_64-pc-cygwin/bits/gthr.h:148, >> >>                   from >> /usr/lib/gcc/x86_64-pc-cygwin/11/include/c++/ext/atomicity.h:35, >>                   from >> /usr/lib/gcc/x86_64-pc-cygwin/11/include/c++/bits/ios_base.h:39, >>                   from >> /usr/lib/gcc/x86_64-pc-cygwin/11/include/c++/iomanip:40, >>                   from >> /home/Hamis/wxwidgets3.1/wxWidgets3.1-3.1.5-1.x86_64/src/wxWidgets-3.1.5/tests/allheaders.cpp:63: >> >> /usr/include/pthread.h:65:5: note: previous declaration of ‘int >> pthread_atfork(void (*)(), void (*)(), void (*)())’ >>     65 | int pthread_atfork (void (*)(void), void (*)(void), void >> (*)(void)); >>        |     ^~~~~~~~~~~~~~ >> >> Ditto. > > Looking at chmod(3p), pthread_atfork(3p), pthread.h(0p) sys_stat.h(0p), > unistd.h(0p) those definitions should *NOT* normally be accessible from > unistd.h so there should be no conflict, as POSIX specifies what is > visible. > Perhaps they are there for compatibility with older systems like BSD or > Solaris and should be suppressed when newer feature macros are defined > or specific legacy system macros are not defined? Perhaps, can anyone else offer any thoughts. I might go ahead and compare the headers from my Linux install to those on Cygwin. Perhaps I need to define a special macro for Cygwin, I guess that's the easiest fix with least possibility of breaking something else? > >> Also of note, is that Cygwin is several times slower at compiling >> pretty much everything for me. Does anyone know if this is GCC 9 vs 11 >> speed, or running Cygwin in Windows 11 in KVM, or something else? I am >> running on AMD Ryzen 3000, if that has anything to do with it. > > VM is always slower than native, Windows than Linux, Cygwin than > Windows, maybe see if Cygwin under Wine is faster than under Windows in > KVM? > Windows 11 may have more instrumentation than 10 especially if Developer > or Insider edition. > Windows performance profile, desktop/laptop busses, CPU count, MT, > speed, memory, SSD/HDD will also have effects. > Oh that's a good idea, I forgot Cygwin finally at least semi works on WINE now. I'll see how fast that is. I don't think I want to use that as a build environment just in case there's a deficiency in WINE that matters during the build, but it might be useful for testing. Hamish