Skip to content

Instantly share code, notes, and snippets.

@dsvensson
Created September 14, 2023 20:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dsvensson/086e2b861a2827b8d09589a024b94af2 to your computer and use it in GitHub Desktop.
Save dsvensson/086e2b861a2827b8d09589a024b94af2 to your computer and use it in GitHub Desktop.
vcpkg static linux build setup
{
"version": 6,
"cmakeMinimumRequired": {
"major": 3,
"minor": 9,
"patch": 0
},
"configurePresets": [
{
"name": "default",
"displayName": "Release",
"description": "Default build using Ninja generator",
"generator": "Ninja",
"cacheVariables": {
"CMAKE_TOOLCHAIN_FILE": "vcpkg/scripts/buildsystems/vcpkg.cmake",
"VCPKG_BUILD_TYPE": "release",
"VCPKG_LIBRARY_LINKAGE": "static",
"VCPKG_CRT_LINKAGE": "dynamic",
"VCPKG_TARGET_ARCHITECTURE": "x64"
},
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Linux"
}
}
],
"buildPresets": [
{
"name": "default",
"configurePreset": "default"
}
],
"workflowPresets": [
{
"name": "default",
"steps": [
{
"type": "configure",
"name": "default"
},
{
"type": "build",
"name": "default"
}
]
}
]
}
@dsvensson
Copy link
Author

missed some setting so it's a debug build, should be trivial to fix:

> du -sh ezquake       
28M	ezquake
> du -sh ezquake-stripped
13M	ezquake-stripped

otherwise:

> ldd ezquake
	linux-vdso.so.1 (0x00007ffdfdb53000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f09c7f8d000)
	libGL.so.1 => /lib/x86_64-linux-gnu/libGL.so.1 (0x00007f09c7f06000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f09bf600000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f09c80a9000)
	libGLdispatch.so.0 => /lib/x86_64-linux-gnu/libGLdispatch.so.0 (0x00007f09bf948000)
	libGLX.so.0 => /lib/x86_64-linux-gnu/libGLX.so.0 (0x00007f09c7ed4000)
	libX11.so.6 => /lib/x86_64-linux-gnu/libX11.so.6 (0x00007f09bf808000)
	libxcb.so.1 => /lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f09bf5d6000)
	libXau.so.6 => /lib/x86_64-linux-gnu/libXau.so.6 (0x00007f09bf5d0000)
	libXdmcp.so.6 => /lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f09bf5c8000)
	libbsd.so.0 => /lib/x86_64-linux-gnu/libbsd.so.0 (0x00007f09bf5b3000)
	libmd.so.0 => /lib/x86_64-linux-gnu/libmd.so.0 (0x00007f09bf5a6000)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment