Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 0.38.1 compiles incorrectly under Windows #55

Open
jimwang118 opened this issue Oct 31, 2024 · 7 comments
Open

Version 0.38.1 compiles incorrectly under Windows #55

jimwang118 opened this issue Oct 31, 2024 · 7 comments
Labels
bug Something isn't working c++ C++ code related investigate Needs investigation vcpkg Vcpkg port

Comments

@jimwang118
Copy link

Steps to reproduce:

  1. git vcpkg
  2. Replace the version in vcpkg under tinyorm with 0.38.1.
  3. ./vcpkg install tinyorm

Error:

C:\PROGRA~1\MICROS~4\2022\ENTERP~1\VC\Tools\MSVC\1438~1.331\bin\Hostx64\x64\cl.exe   /TP -DNOMINMAX -DNTDDI_VERSION=NTDDI_WIN10_NI -DPROJECT_TINYORM -DQT_CORE_LIB -DQT_NO_CAST_FROM_BYTEARRAY -DQT_NO_CAST_TO_ASCII -DQT_NO_KEYWORDS -DQT_SQL_LIB -DQT_STRICT_ITERATORS -DTINYORM_BUILDING_SHARED -DTINYORM_DEBUG -DTINYORM_DEBUG_SQL -DTINYORM_EXTERN_CONSTANTS -DTINYORM_LTO=tinyHasLTO-NOTFOUND -DTINYORM_MSVC_RUNTIME_DYNAMIC=MSVC_RUNTIME_DYNAMIC-NOTFOUND -DTINYORM_PRAGMA_SYSTEM_HEADER_OFF -DTINYORM_STRICT_MODE=OFF -DTINYORM_USING_PCH -DTINYORM_USING_QTSQLDRIVERS -DTINYTOM_CMAKE_MSVC_RUNTIME_LIBRARY=MultiThreadedDebugDLL -DTINYTOM_DEBUG -DTinyOrm_EXPORTS -DUNICODE -DWIN32 -DWIN32_LEAN_AND_MEAN -DWIN64 -DWINVER=_WIN32_WINNT_WIN10 -D_ENABLE_EXTENDED_ALIGNED_STORAGE -D_SILENCE_STDEXT_ARR_ITERS_DEPRECATION_WARNING -D_UNICODE -D_WIN32_IE=_WIN32_IE_IE110 -D_WIN32_WINNT=_WIN32_WINNT_WIN10 -D_WIN64 -IF:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\include -IF:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\tom\include -external:IF:\vcpkg\installed\x64-windows\include\Qt6\QtCore -external:IF:\vcpkg\installed\x64-windows\include\Qt6 -external:IF:\vcpkg\installed\x64-windows\share\Qt6\mkspecs\win32-msvc -external:IF:\vcpkg\installed\x64-windows\include -external:IF:\vcpkg\installed\x64-windows\include\Qt6\QtSql -external:W0 /nologo /DWIN32 /D_WINDOWS /utf-8 /GR /EHsc /MP  /D_DEBUG /MDd /Z7 /Ob0 /Od /RTC1  -std:c++20 -MDd -Zc:__cplusplus -permissive- -utf-8 /permissive- /nologo /EHsc /utf-8 /Zc:__cplusplus /Zc:strictStrings /guard:cf /bigobj /Zc:wchar_t,rvalueCast,inline /Zc:throwingNew,referenceBinding,ternary /Zc:preprocessor /external:anglebrackets /external:W0 /wd4702 /YuF:/vcpkg/buildtrees/tinyorm/x64-windows-dbg/CMakeFiles/TinyOrm.dir/cmake_pch.hxx /FpF:/vcpkg/buildtrees/tinyorm/x64-windows-dbg/CMakeFiles/TinyOrm.dir/./cmake_pch.cxx.pch /FIF:/vcpkg/buildtrees/tinyorm/x64-windows-dbg/CMakeFiles/TinyOrm.dir/cmake_pch.hxx /showIncludes /FoCMakeFiles\TinyOrm.dir\src\orm\basegrammar.cpp.obj /FdCMakeFiles\TinyOrm.dir\ /FS -c F:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\src\orm\basegrammar.cpp
F:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\include\orm/utils/integralcast.hpp(58): error C2338: static_assert failed: 'Unhandled code branch in the Private::IntegralTypeName<T>() (long).'
F:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\include\orm/utils/integralcast.hpp(80): error C2338: static_assert failed: 'Unhandled code branch in the Private::IntegralTypeName<T>() (ulong).'
F:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\include\orm/utils/integralcast.hpp(108): error C2338: static_assert failed: 'Unhandled code branch in the Private::IntegralTypeName<T>().'
F:\vcpkg\buildtrees\tinyorm\src\v0.38.1-ac7e6386e6.clean\include\orm/utils/integralcast.hpp(237): error C2338: static_assert failed: 'Unhandled code branch in the Private::InRange<T, V>().'
@silverqx silverqx added bug Something isn't working c++ C++ code related investigate Needs investigation vcpkg Vcpkg port labels Oct 31, 2024
@silverqx
Copy link
Owner

Do you have log files? Something like config-x64-windows-err.log where is the whole stacktrace, I would like to see which line is causing it. I'm compiling it daily on all platforms and never saw this error, maybe old compiler? Here are min. Supported compilers, but I didn't try v16.9 a looong time.

I'm not prepared to do the next release. Stabilizing the current code base would take a week, and I still have another 100 todos on the list. I'm halfway through the job and I don't even know when I will do the next release.

@silverqx
Copy link
Owner

It looks like I forgot to post v0.38.1 to the vcpkg repo.

@jimwang118
Copy link
Author

install-x64-windows-dbg-out.log

@silverqx
Copy link
Owner

Thx, there is nothing more, really, the stacktrace doesn't go outside of that integralcast.hpp.

Do you know the MSVC version? It looks like 17.8, if so that should be ok, but apparently its not 😵‍💫.

@jimwang118
Copy link
Author

Thx, there is nothing more, really, the stacktrace doesn't go outside of that integralcast.hpp.

Do you know the MSVC version? It looks like 17.8, if so that should be ok, but apparently its not 😵‍💫.

I am using msvc 17.8.4.

@silverqx
Copy link
Owner

Now I tried it on 17.11 and it compiles.

Installing 1/1 tinyorm[core,debug,orm,sql-mysql,tom,tom-example]:x64-windows@0.38.1...
Building tinyorm[core,debug,orm,sql-mysql,tom,tom-example]:x64-windows@0.38.1...

So the problem will be in 17.8, I will fix it, problem is in constexpr code.

@silverqx
Copy link
Owner

Thx for reporting it anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working c++ C++ code related investigate Needs investigation vcpkg Vcpkg port
Projects
None yet
Development

No branches or pull requests

2 participants