Skip to content

Commit a49e4b8

Browse files
committed
util: Log build target name
1 parent 791d20e commit a49e4b8

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

src/meson.build

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ nvapi_src = files([
2626
'nvapi_interface.cpp',
2727
])
2828

29-
nvapi_dll = shared_library('nvapi'+target_suffix, [ nvapi_src, dxvk_nvapi_version ],
29+
target_name = 'nvapi'+target_suffix
30+
nvapi_dll = shared_library(target_name, [ nvapi_src, dxvk_nvapi_version ],
31+
cpp_args : '-DDXVK_NVAPI_TARGET_NAME="'+target_name+'"',
3032
name_prefix : '',
3133
dependencies : [ lib_dxgi, lib_d3d11, lib_version ],
3234
include_directories : [ nvapi_headers, vk_headers ],
@@ -47,7 +49,9 @@ nvofapi_src = files([
4749

4850
# Only build 64-bit versions of nvofapi
4951
if dxvk_cpu_family == 'x86_64'
50-
nvofapi_dll = shared_library('nvofapi'+target_suffix, [ nvofapi_src, dxvk_nvapi_version ],
52+
target_name = 'nvofapi'+target_suffix
53+
nvofapi_dll = shared_library(target_name, [ nvofapi_src, dxvk_nvapi_version ],
54+
cpp_args : '-DDXVK_NVAPI_TARGET_NAME="'+target_name+'"',
5155
name_prefix : '',
5256
dependencies : [ lib_version ],
5357
include_directories : [ nvapi_headers, vk_headers ],

src/util/util_log.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ namespace dxvk::log {
8282
std::setfill('0'), std::setw(4), std::hex, ::GetCurrentProcessId(), ":",
8383
std::setfill('0'), std::setw(4), std::hex, ::GetCurrentThreadId(), ":",
8484
level, ":",
85-
"dxvk-nvapi:",
85+
DXVK_NVAPI_TARGET_NAME, ":",
8686
message);
8787

8888
print(logMessage);

tests/meson.build

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ nvapi_tests_src = files([
4242
'util.cpp',
4343
])
4444

45-
nvapi_exe = executable('nvapi'+target_suffix+'-tests', [ nvapi_src, catch2_src, nvapi_tests_src, dxvk_nvapi_version ],
45+
target_name = 'nvapi'+target_suffix+'-tests'
46+
nvapi_exe = executable(target_name, [ nvapi_src, catch2_src, nvapi_tests_src, dxvk_nvapi_version ],
47+
cpp_args : '-DDXVK_NVAPI_TARGET_NAME="'+target_name+'"',
4648
dependencies : [ lib_dxgi, lib_d3d11, lib_version ],
4749
include_directories : [ nvapi_headers, vk_headers ],
4850
install : true)

0 commit comments

Comments
 (0)