From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8B54D394742F; Fri, 1 Apr 2022 15:25:51 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8B54D394742F From: "samuel.d.darwin at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/105127] New: Search Path not working on Cygwin Date: Fri, 01 Apr 2022 15:25:50 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 11.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: samuel.d.darwin at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Apr 2022 15:25:51 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105127 Bug ID: 105127 Summary: Search Path not working on Cygwin Product: gcc Version: 11.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: samuel.d.darwin at gmail dot com Target Milestone: --- Hi, It appears that "Search Path" is not working as expected on the Cygwin platform. Your feedback would be appreciated. Notice on this page https://gcc.gnu.org/onlinedocs/cpp/Search-Path.html it says: By default, the preprocessor looks for header files included by the q= uote form of the directive #include "file" first relative to the directory of the current file, and then in a preconfigured list of standard system directori= es.=20 However, during testing, g++ fails to include a file in the same directory.= An error such as this occurs: "fatal error: zutil.h: No such file or directory | #include "zutil.h" compilation terminated." How can it be replicated? The problem was discovered when running CI tests https://github.com/boostorg/boost-ci . Notice the .appveyor.yml file contai= ned there. To run more Cygwin tests I forked that repository to https://github.com/samd2/boost-ci/tree/feature/searchpath and added Visual Studio 2019 and Visual Studio 2022 images. Appveyor's Visual Studio 2017 im= age was ok. The problem appears on 2019 and 2022. CI output at https://ci.appveyor.com/project/sam-original/boost-ci/builds/43100905 > Which version of gcc?=20 # gcc -v Using built-in specs. COLLECT_GCC=3Dgcc COLLECT_LTO_WRAPPER=3D/usr/lib/gcc/x86_64-pc-cygwin/11/lto-wrapper.exe Target: x86_64-pc-cygwin Configured with: /mnt/share/cygpkgs/gcc/gcc.x86_64/src/gcc-11.2.0/configure --srcdir=3D/mnt/share/cygpkgs/gcc/gcc.x86_64/src/gcc-11.2.0 --prefix=3D/usr --exec-prefix=3D/usr --localstatedir=3D/var --sysconfdir=3D/etc --docdir=3D/usr/share/doc/gcc --htmldir=3D/usr/share/doc/gcc/html -C --build=3Dx86_64-pc-cygwin --host=3Dx86_64-pc-cygwin --target=3Dx86_64-pc-c= ygwin --without-libiconv-prefix --without-libintl-prefix --libexecdir=3D/usr/lib --with-gcc-major-version-only --enable-shared --enable-shared-libgcc --enable-static --enable-version-specific-runtime-libs --enable-bootstrap --enable-__cxa_atexit --with-dwarf2 --with-tune=3Dgeneric --disable-bootstr= ap --enable-languages=3Dc,c++,fortran,lto,objc,obj-c++,jit --enable-graphite --enable-threads=3Dposix --enable-libatomic --enable-libgomp --enable-libqu= admath --enable-libquadmath-support --disable-libssp --enable-libada --disable-sym= vers --with-gnu-ld --with-gnu-as --with-cloog-include=3D/usr/include/cloog-isl --without-libiconv-prefix --without-libintl-prefix --with-system-zlib --enable-linker-build-id --with-default-libstdcxx-abi=3Dgcc4-compatible --enable-libstdcxx-filesystem-ts Thread model: posix Supported LTO compression algorithms: zlib zstd gcc version 11.2.0 (GCC)=20 b2 --abbreviate-paths libs/boost-ci/test toolset=3Dgcc cxxstd=3D11,14,1z=20= =20=20 address-model=3D64 link=3Dshared,static variant=3Drelease -j3=20 > What command failed? Actually, g++ was called by another tools, b2 : b2 --abbreviate-paths libs/boost-ci/test toolset=3Dgcc cxxstd=3D11,14,1z=20= =20=20 address-model=3D64 link=3Dshared,static variant=3Drelease -j3=20 By adding the -d2 debugging flag to b2 it can be seen that the g++ command = was: g++ -std=3Dc++14 -fvisibility-inlines-hidden -m64 -mthreads -O3 -finline-functions -Wno-inline -Wall -fvisibility=3Dhidden -DBOOST_ALL_NO_= LIB=3D1 -DNDEBUG -I"." -c -o "bin.v2\libs\boost-ci\test\gcc-11\rls\cxstd-14-iso\trgt-os-cygwn\thrd-mlt\v= sblt-hdn\test.o" "libs\boost-ci\test\test.cpp" > What was the C++ source file contents?=20 In this case the file test.cpp. It can be seen here: https://github.com/boostorg/boost-ci/blob/master/test/test.cpp It has the line "#include "test2.hpp" > What was the exact error? libs\boost-ci\test\test.cpp:18:10: fatal error: test2.hpp: No such file or directory 18 | #include "test2.hpp" | ^~~~~~~~~ View the entire build here:=20 https://ci.appveyor.com/project/sam-original/boost-ci/builds/43100905 Let me know if you need more info. Thanks.=