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

[MSVC] Torque2D failed to build due to error LNK2001: unresolved external symbol __imp_ldexp on x64 on Windows #66

Open
Od0VxibTqto6Hs opened this issue May 12, 2023 · 0 comments

Comments

@Od0VxibTqto6Hs
Copy link

Torque2D failed to build with msvc due to error LNK2001: unresolved external symbol __imp_ldexp, this error appears only on x64 mode. Reproduce steps and error message as follows.

Torque2D version

master v4.0-ea2.1 2c555d6 e79c058

Windows build number

10.0.20348.0

Visual Studio version

VS2022 17.5.4

Steps to reproduce

git clone https://github.com/TorqueGameEngines/Torque2D F:\repo\TorqueGameEngines\Torque2D
git -C "F:\repo\TorqueGameEngines\Torque2D" reset --hard e79c058
git -C "F:\repo\TorqueGameEngines\Torque2D" submodule sync
git -C "F:\repo\TorqueGameEngines\Torque2D" submodule foreach git reset --hard
git -C "F:\repo\TorqueGameEngines\Torque2D" submodule foreach git clean -xdf
F:\repo\TorqueGameEngines\Torque2D" submodule update --init --recursive
set VSCMD_SKIP_SENDTELEMETRY=1 & "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -host_arch=amd64 -arch=amd64
mkdir F:\repo\TorqueGameEngines\Torque2D\build_amd64
cd F:\repo\TorqueGameEngines\Torque2D\build_amd64

devenv /upgrade "..\engine\compilers\VisualStudio 2019\Torque 2D.sln

set INCLUDE=F:\repo\TorqueGameEngines\Torque2D\engine\lib\libogg\include;%INCLUDE%
set INCLUDE=F:\repo\TorqueGameEngines\Torque2D\engine\lib\libvorbis\include;%INCLUDE%
set INCLUDE=F:\repo\TorqueGameEngines\Torque2D\engine\lib\libvorbis\lib;%INCLUDE%
msbuild /m /p:Platform=x64 /p:Configuration=Release "..\engine\compilers\VisualStudio 2019\Torque 2D.sln" /p:UseEnv=true /t:Rebuild /p:Outdir=F:\repo\TorqueGameEngines\Torque2D\build_amd64 2>&1

I tried the latest commit: 2c555d6, the issue still can be reproduced.

Error info

"F:\repo\TorqueGameEngines\Torque2D\engine\compilers\VisualStudio 2019\Torque 2D.sln" (Rebuild target) (1) ->
"F:\repo\TorqueGameEngines\Torque2D\engine\compilers\VisualStudio 2019\Torque 2D.vcxproj" (Rebuild target) (2) ->
(Link target) -> 
  libvorbis.lib(sharedbook.obj) : error LNK2001: unresolved external symbol __imp_ldexp [F:\repo\TorqueGameEngines\Torque2D\engine\compilers\VisualStudio 2019\Torque 2D.vcxproj]
  ..\..\..\Torque2D.exe : fatal error LNK1120: 1 unresolved externals [F:\repo\TorqueGameEngines\Torque2D\engine\compilers\VisualStudio 2019\Torque 2D.vcxproj]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant