• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Compiling Error Compiling OTCv8 - LNK 2001 unresolved external symbol __std_remove_1

opsdan

New Member
Joined
May 7, 2010
Messages
16
Solutions
1
Reaction score
0
I'm trying to compile otclientv8 from OTAcademy (GitHub - OTAcademy/otclientv8: Mirror of official OTClientV8 (https://github.com/OTAcademy/otclientv8)) using Visual Studio 2022 and Boost 1.62.0, but I've been stuck with these errors for a few days now:

1744292220812.webp

Severity Code Description Project File Line Suppression State Details
Error LNK2001 unresolved external symbol __std_search_1 otclient C:\vcpkg\otclientv8-master\vc17\OpenAL32.lib(context.cpp.obj) 1

Severity Code Description Project File Line Suppression State Details
Error LNK2001 unresolved external symbol __std_remove_8 otclient C:\vcpkg\otclientv8-master\vc17\OpenAL32.lib(auxeffectslot.cpp.obj) 1

Severity Code Description Project File Line Suppression State Details
Error LNK2001 unresolved external symbol __std_remove_1 otclient C:\vcpkg\otclientv8-master\vc17\OpenAL32.lib(cpu_caps.cpp.obj) 1

I've already tried pointing Linker > General > Additional Library Directories to every possible folder containing .lib files, but no success. I even deleted the entire vcpkg/boost installation and reinstalled everything again, but still no luck.

What could be causing this? Thanks in advance.
 
@oen432
I have added this to linker > general:
LUA:
C:\Program Files %28x86%29\Windows Kits\10\Lib\10.0.22621.0\um\x64;%(AdditionalLibraryDirectories)

and this Linker > Input > Additional dependencies at the end:
Code:
$(OTCLIENT_LIBDEPS);glew32.lib;opengl32.lib;avrt.lib

even here at C/C++:
Code:
C:\Program Files %28x86%29\Windows Kits\10\Lib\10.0.22621.0\um\x64;%(AdditionalIncludeDirectories)

I got even more errors. I have tried various combinations

before errors 7:
Code:
1>libcrypto.lib(libcrypto-lib-params.obj) : error LNK2001: unresolved external symbol __dtoul3_legacy
1>zip.lib(zip_algorithm_bzip2.c.obj) : error LNK2001: unresolved external symbol __dtoul3_legacy
1>OpenAL32.lib(alc.cpp.obj) : error LNK2001: unresolved external symbol ___std_init_once_link_alternate_names_and_abort@0
1>OpenAL32.lib(source.cpp.obj) : error LNK2001: unresolved external symbol __ltof3
1>OpenAL32.lib(auxeffectslot.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_4@12
1>OpenAL32.lib(null.cpp.obj) : error LNK2001: unresolved external symbol __Thrd_sleep_for@4
1>OpenAL32.lib(wave.cpp.obj) : error LNK2001: unresolved external symbol __Thrd_sleep_for@4
1>OpenAL32.lib(cpu_caps.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_1@12
1>OpenAL32.lib(ambdec.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_1@12
1>OpenAL32.lib(hrtf.cpp.obj) : error LNK2001: unresolved external symbol ___std_max_element_d@12
1>otclient_gl.exe : fatal error LNK1120: 7 unresolved externals
1>Done building project "otclient.vcxproj" -- FAILED.


after errors 372:
Code:
300+ lines more
...
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SubmitThreadpoolWork@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolWork@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CreateThreadpoolTimer@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SetThreadpoolTimer@16
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__WaitForThreadpoolTimerCallbacks@8
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolTimer@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CreateThreadpoolWait@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SetThreadpoolWait@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolWait@4
1>libcpmt.lib(StlCompareStringA.obj) : error LNK2001: unresolved external symbol __imp__CompareStringEx@36
1>libcpmt.lib(StlCompareStringW.obj) : error LNK2001: unresolved external symbol __imp__CompareStringEx@36
1>libcpmt.lib(StlCompareStringA.obj) : error LNK2001: unresolved external symbol __imp__GetCPInfo@8
1>libcpmt.lib(xdateord.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoEx@16
1>libcpmt.lib(xgetwctype.obj) : error LNK2001: unresolved external symbol __imp__GetStringTypeW@16
1>otclient_gl.exe : fatal error LNK1120: 372 unresolved externals
 
@oen432
I have added this to linker > general:
LUA:
C:\Program Files %28x86%29\Windows Kits\10\Lib\10.0.22621.0\um\x64;%(AdditionalLibraryDirectories)

and this Linker > Input > Additional dependencies at the end:
Code:
$(OTCLIENT_LIBDEPS);glew32.lib;opengl32.lib;avrt.lib

even here at C/C++:
Code:
C:\Program Files %28x86%29\Windows Kits\10\Lib\10.0.22621.0\um\x64;%(AdditionalIncludeDirectories)

I got even more errors. I have tried various combinations

before errors 7:
Code:
1>libcrypto.lib(libcrypto-lib-params.obj) : error LNK2001: unresolved external symbol __dtoul3_legacy
1>zip.lib(zip_algorithm_bzip2.c.obj) : error LNK2001: unresolved external symbol __dtoul3_legacy
1>OpenAL32.lib(alc.cpp.obj) : error LNK2001: unresolved external symbol ___std_init_once_link_alternate_names_and_abort@0
1>OpenAL32.lib(source.cpp.obj) : error LNK2001: unresolved external symbol __ltof3
1>OpenAL32.lib(auxeffectslot.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_4@12
1>OpenAL32.lib(null.cpp.obj) : error LNK2001: unresolved external symbol __Thrd_sleep_for@4
1>OpenAL32.lib(wave.cpp.obj) : error LNK2001: unresolved external symbol __Thrd_sleep_for@4
1>OpenAL32.lib(cpu_caps.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_1@12
1>OpenAL32.lib(ambdec.cpp.obj) : error LNK2001: unresolved external symbol ___std_find_trivial_1@12
1>OpenAL32.lib(hrtf.cpp.obj) : error LNK2001: unresolved external symbol ___std_max_element_d@12
1>otclient_gl.exe : fatal error LNK1120: 7 unresolved externals
1>Done building project "otclient.vcxproj" -- FAILED.


after errors 372:
Code:
300+ lines more
...
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SubmitThreadpoolWork@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolWork@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CreateThreadpoolTimer@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SetThreadpoolTimer@16
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__WaitForThreadpoolTimerCallbacks@8
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolTimer@4
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CreateThreadpoolWait@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__SetThreadpoolWait@12
1>libcpmt.lib(winapisupp.obj) : error LNK2001: unresolved external symbol __imp__CloseThreadpoolWait@4
1>libcpmt.lib(StlCompareStringA.obj) : error LNK2001: unresolved external symbol __imp__CompareStringEx@36
1>libcpmt.lib(StlCompareStringW.obj) : error LNK2001: unresolved external symbol __imp__CompareStringEx@36
1>libcpmt.lib(StlCompareStringA.obj) : error LNK2001: unresolved external symbol __imp__GetCPInfo@8
1>libcpmt.lib(xdateord.obj) : error LNK2001: unresolved external symbol __imp__GetLocaleInfoEx@16
1>libcpmt.lib(xgetwctype.obj) : error LNK2001: unresolved external symbol __imp__GetStringTypeW@16
1>otclient_gl.exe : fatal error LNK1120: 372 unresolved externals
try
vcpkg remove openal-soft openssl libzip
vcpkg install openal-soft openssl libzip --triplet=x64-windows
in the before version
 
try
vcpkg remove openal-soft openssl libzip
vcpkg install openal-soft openssl libzip --triplet=x64-windows
in the before version

I use vcpkg manifest. I do not install manualy. Installation via vcpkg.json is much more convenient.
LUA:
{
    "name": "otclient",
    "version-string": "1.0.0",
    "dependencies": [
        "boost-asio",
        "boost-beast",
        "boost-system",
        "boost-variant",
        "boost-lockfree",
        "boost-program-options"
        "boost-filesystem",
        "boost-uuid",
        "boost-process",
        "boost-iostreams",
        "openssl",
        "physfs",
        "libogg",
        "libvorbis",
        "openal-soft",
        "luajit",
        "glew",
        "zlib",
        "libzip"
    ],
    "overrides": [
        {
            "name": "openal-soft",
            "version": "1.22.2"
        },
        {
            "name": "physfs",
            "version": "3.0.2"
        }
    ],
    "features": {
        "openal-soft": {
          "description": "Enable AVRT support",
          "dependencies": ["avrt-support"]
        }
    },
    "builtin-baseline": "b322364f06308bdd24823f9d8f03fe0cc86fd46f"
}

I have this in vcpkg_installed directory
1744881555408.webp1744881518776.webp

Can i set parameter"--triplet=x64-windows" in vcpkg.json?
 
I use vcpkg manifest. I do not install manualy. Installation via vcpkg.json is much more convenient.
LUA:
{
    "name": "otclient",
    "version-string": "1.0.0",
    "dependencies": [
        "boost-asio",
        "boost-beast",
        "boost-system",
        "boost-variant",
        "boost-lockfree",
        "boost-program-options"
        "boost-filesystem",
        "boost-uuid",
        "boost-process",
        "boost-iostreams",
        "openssl",
        "physfs",
        "libogg",
        "libvorbis",
        "openal-soft",
        "luajit",
        "glew",
        "zlib",
        "libzip"
    ],
    "overrides": [
        {
            "name": "openal-soft",
            "version": "1.22.2"
        },
        {
            "name": "physfs",
            "version": "3.0.2"
        }
    ],
    "features": {
        "openal-soft": {
          "description": "Enable AVRT support",
          "dependencies": ["avrt-support"]
        }
    },
    "builtin-baseline": "b322364f06308bdd24823f9d8f03fe0cc86fd46f"
}

I have this in vcpkg_installed directory
View attachment 91866View attachment 91865

Can i set parameter"--triplet=x64-windows" in vcpkg.json?
yes, i used it because it for some reason downloaded x64-windows while im using x64-arm
 
I copied the Visual Studio settings from my previous client environment, and it worked. I'm sharing a screenshot of the changes in file otclient.vcxproj here in case anyone finds it helpful

1744885015778.webp
1744885032152.webp
1744885053281.webp
 
Back
Top