Skip to content

Add mingw build to GitHub actions #625

@mckib2

Description

@mckib2

On latest master, I have attempted a build on a clean install of Windows 10 using mingw installed via chocolately:

mkdir build
cd build
cmake -G Ninja ..
ninja -j8

Several warnings and the following error are emitted:

[7/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj
FAILED: check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj
C:\ProgramData\chocolatey\bin\c++.exe  -IC:/Users/nmckibben/Documents/HiGHS/build -IC:/Users/nmckibben/Documents/HiGHS/app -IC:/Users/nmckibben/Documents/HiGHS/extern -IC:/Users/nmckibben/Documents/HiGHS/src -IC:/Users/nmckibben/Documents/HiGHS/src/io -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu -IC:/Users/nmckibben/Documents/HiGHS/src/lp_data -IC:/Users/nmckibben/Documents/HiGHS/src/mip -IC:/Users/nmckibben/Documents/HiGHS/src/model -IC:/Users/nmckibben/Documents/HiGHS/src/presolve -IC:/Users/nmckibben/Documents/HiGHS/src/qpsolver -IC:/Users/nmckibben/Documents/HiGHS/src/simplex -IC:/Users/nmckibben/Documents/HiGHS/src/test -IC:/Users/nmckibben/Documents/HiGHS/src/util -IC:/Users/nmckibben/Documents/HiGHS/src/extern/catch -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx/src -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu/src -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx/include -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu/include -Wall -Wextra -Wno-unused-parameter -Wno-format-truncation -pedantic -fdiagnostics-color=always -O3 -DNDEBUG -std=gnu++11 -MD -MT check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj -MF check\CMakeFiles\unit_tests.dir\TestIO.cpp.obj.d -o check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj -c C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp
In file included from C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp:5:
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp: In instantiation of 'bool Catch::compareNotEqual(const LhsT&, RhsT&&) [with LhsT = char*; RhsT = const long long int&]':
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp:2348:37:   required from 'const Catch::BinaryExpr<LhsT, const RhsT&> Catch::ExprLhs<LhsT>::operator!=(const RhsT&) [with RhsT = long long int; LhsT = char* const&]'
C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp:66:5:   required from here
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp:2322:96: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]

Full output:

Details
C:\Users\nmckibben\Documents\HiGHS\build>cmake -G Ninja ..
-- The CXX compiler identification is GNU 11.2.0
-- The C compiler identification is GNU 11.2.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/ProgramData/chocolatey/bin/c++.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/ProgramData/chocolatey/bin/gcc.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Performing Test HIGHS_HAVE_MM_PAUSE
-- Performing Test HIGHS_HAVE_MM_PAUSE - Success
-- Performing Test HIGHS_HAVE_BUILTIN_CLZ
-- Performing Test HIGHS_HAVE_BUILTIN_CLZ - Success
-- Performing Test flag_supported
-- Performing Test flag_supported - Success
-- Performing Test flag_supported
-- Performing Test flag_supported - Success
-- Performing Test flag_supported
-- Performing Test flag_supported - Success
-- Performing Test flag_supported
-- Performing Test flag_supported - Success
-- Performing Test flag_supported
-- Performing Test flag_supported - Success
-- Looking for a Fortran compiler
-- Looking for a Fortran compiler - C:/ProgramData/chocolatey/bin/gfortran.exe
-- The Fortran compiler identification is GNU 11.2.0
-- Detecting Fortran compiler ABI info
-- Detecting Fortran compiler ABI info - done
-- Check for working Fortran compiler: C:/ProgramData/chocolatey/bin/gfortran.exe - skipped
-- Looking for a CSharp compiler
-- Looking for a CSharp compiler - NOTFOUND
-- Performing Test NO_OMIT_FRAME_POINTER_FLAG_SUPPORTED
-- Performing Test NO_OMIT_FRAME_POINTER_FLAG_SUPPORTED - Success
-- Git hash: eeb455ff
-- Compilation date: 2021-12-10
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
-- Build shared libraries: ON
-- Build type: Release
-- No CSharp support
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Performing Test COMPILER_HAS_DEPRECATED_ATTR
-- Performing Test COMPILER_HAS_DEPRECATED_ATTR - Success
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Users/nmckibben/Documents/HiGHS/build

C:\Users\nmckibben\Documents\HiGHS\build>ninja -j4
[1/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestEkk.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestEkk.cpp:1:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[2/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestDualise.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestDualise.cpp:1:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[3/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestAlienBasis.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestAlienBasis.cpp:3:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[5/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestCheckSolution.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestCheckSolution.cpp:3:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[6/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestFreezeBasis.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestFreezeBasis.cpp:1:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[7/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj
FAILED: check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj
C:\ProgramData\chocolatey\bin\c++.exe  -IC:/Users/nmckibben/Documents/HiGHS/build -IC:/Users/nmckibben/Documents/HiGHS/app -IC:/Users/nmckibben/Documents/HiGHS/extern -IC:/Users/nmckibben/Documents/HiGHS/src -IC:/Users/nmckibben/Documents/HiGHS/src/io -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu -IC:/Users/nmckibben/Documents/HiGHS/src/lp_data -IC:/Users/nmckibben/Documents/HiGHS/src/mip -IC:/Users/nmckibben/Documents/HiGHS/src/model -IC:/Users/nmckibben/Documents/HiGHS/src/presolve -IC:/Users/nmckibben/Documents/HiGHS/src/qpsolver -IC:/Users/nmckibben/Documents/HiGHS/src/simplex -IC:/Users/nmckibben/Documents/HiGHS/src/test -IC:/Users/nmckibben/Documents/HiGHS/src/util -IC:/Users/nmckibben/Documents/HiGHS/src/extern/catch -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx/src -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu/src -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/ipx/include -IC:/Users/nmckibben/Documents/HiGHS/src/ipm/basiclu/include -Wall -Wextra -Wno-unused-parameter -Wno-format-truncation -pedantic -fdiagnostics-color=always -O3 -DNDEBUG -std=gnu++11 -MD -MT check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj -MF check\CMakeFiles\unit_tests.dir\TestIO.cpp.obj.d -o check/CMakeFiles/unit_tests.dir/TestIO.cpp.obj -c C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp
In file included from C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp:5:
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp: In instantiation of 'bool Catch::compareNotEqual(const LhsT&, RhsT&&) [with LhsT = char*; RhsT = const long long int&]':
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp:2348:37:   required from 'const Catch::BinaryExpr<LhsT, const RhsT&> Catch::ExprLhs<LhsT>::operator!=(const RhsT&) [with RhsT = long long int; LhsT = char* const&]'
C:/Users/nmckibben/Documents/HiGHS/check/TestIO.cpp:66:5:   required from here
C:/Users/nmckibben/Documents/HiGHS/extern/catch.hpp:2322:96: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
 2322 |     auto compareNotEqual( LhsT const& lhs, RhsT&& rhs ) -> bool { return static_cast<bool>(lhs != rhs); }
      |                                                                                            ~~~~^~~~~~
[8/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestHotStart.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestHotStart.cpp:1:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[9/213] Building CXX object check/CMakeFiles/unit_tests.dir/TestOptions.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/check/TestOptions.cpp:4:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
[10/213] Building CXX object app/CMakeFiles/highs.dir/RunHighs.cpp.obj
In file included from C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsLpSolverObject.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/lp_data/HighsRanging.h:21,
                 from C:/Users/nmckibben/Documents/HiGHS/src/Highs.h:22,
                 from C:/Users/nmckibben/Documents/HiGHS/app/RunHighs.cpp:16:
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h: In instantiation of 'class HighsHashTable<long long unsigned int>':
C:/Users/nmckibben/Documents/HiGHS/src/simplex/HEkk.h:139:28:   required from here
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:816:41: warning: 'this' pointer is null [-Wnonnull]
  816 |       reinterpret_cast<Entry*>(0)->value())>::type;
      |       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
C:/Users/nmckibben/Documents/HiGHS/src/util/HighsHash.h:791:12: note: in a call to non-static member function 'const T& HighsHashTableEntry<T, void>::value() const [with T = long long unsigned int]'
  791 |   const T& value() const { return value_; }
      |            ^~~~~
ninja: build stopped: subcommand failed.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions