In article <
AS4PR10MB6110B23632...@AS4PR10MB6110.EURPRD10.PROD.OUTLOOK.COM> you write:
>I was trying to build a (simple) wxWidgets application for x86 platform.
>Therefore, I built wxWidgets from source: I choose wx_vc18 solution and
>built it as DLL Release - Win32.
>I extracted the wxWidgets source code .zip in the folder C:\wx\source_3.3.3
>
>When compiling my app, I got a lot of linker error, in particular LNK2002
>"unresolved external symbol..."
It's simpler to just use CMake to generate the project and solution.
With the below CMakeUserPresets.json file in the wxWidgets source
directory, next to CMakePresets.json, the following builds and links
everything 32-bit with no problem:
First, configure to generate project/solution files:
cmake --preset default32
Then you can either build from the solution or with cmake:
cmake --build --preset default32
Pay attention to the output from the first command to see where
wxWidgets wants to write the project/solution files by default. I
place them elsewhere, but omitted that customization to keep this
example simple.
-- Richard
====== CMakeUserPresets.json
{
"version": 6,
"cmakeMinimumRequired": {
"major": 3,
"minor": 23,
"patch": 0
},
"configurePresets": [
{
"name": "default32",
"displayName": "Configure with default 32-bit settings",
"inherits": [
"with_samples",
"with_tests"
],
"architecture": {
"value": "Win32",
"strategy": "set"
},
"generator": "Visual Studio 18 2026"
}
],
"buildPresets": [
{
"name": "default32",
"displayName": "Build with default 32-bit settings",
"configurePreset": "default32"
}
],
"testPresets": [
{
"name": "default32",
"displayName": "Test with default 32-bit settings",
"configurePreset": "default32",
"configuration": "Release",
"output": {
"outputOnFailure": true
}
}
],
"workflowPresets": [
{
"name": "default32",
"displayName": "Workflow with default 32-bit settings: configure, build and test",
"steps": [
{
"type": "configure",
"name": "default32"
},
{
"type": "build",
"name": "default32"
},
{
"type": "test",
"name": "default32"
}
]
}
]
}
====== CMakeUserPresets.json
--
"The Direct3D Graphics Pipeline" free book <
http://tinyurl.com/d3d-pipeline>
The Terminals Wiki <
http://terminals-wiki.org>
The Computer Graphics Museum <
http://computergraphicsmuseum.org>
Legalize Adulthood! (my blog) <
http://legalizeadulthood.wordpress.com>