let dub use the optional bindbc based bindings if user opts in (WARNING UNTESTED)

This commit is contained in:
Adam D. Ruppe 2023-06-01 12:44:56 -04:00
parent 3e01b447f5
commit 6815db255a
2 changed files with 18 additions and 3 deletions

View File

@ -67,7 +67,16 @@
"arsd-official:simpledisplay":"*", "arsd-official:simpledisplay":"*",
"arsd-official:image_files":"*", "arsd-official:image_files":"*",
"arsd-official:svg":"*", "arsd-official:svg":"*",
"arsd-official:ttf":"*" "arsd-official:ttf":"*",
"bindbc-freetype": {
"version": "*",
"optional": true,
},
"bindbc-opengl": {
"version": "*",
"optional": true,
},
}, },
"importPaths": ["."], "importPaths": ["."],
"libs-posix": ["freetype", "fontconfig"], "libs-posix": ["freetype", "fontconfig"],

View File

@ -576,9 +576,15 @@ version (bindbc) {
version = nanovg_builtin_freetype_bindings; version = nanovg_builtin_freetype_bindings;
version = nanovg_builtin_opengl_bindings; // use `arsd.simpledisplay` to get basic bindings version = nanovg_builtin_opengl_bindings; // use `arsd.simpledisplay` to get basic bindings
} else { } else {
version (Have_bindbc_opengl)
version = nanovg_bindbc_opengl_bindings;
else
version = nanovg_builtin_opengl_bindings; // use `arsd.simpledisplay` to get basic bindings
version (Have_bindbc_freetype)
version = nanovg_bindbc_freetype_bindings;
else
version = nanovg_builtin_freetype_bindings;
version = nanovg_builtin_fontconfig_bindings; version = nanovg_builtin_fontconfig_bindings;
version = nanovg_builtin_freetype_bindings;
version = nanovg_builtin_opengl_bindings; // use `arsd.simpledisplay` to get basic bindings
} }
version(nanovg_disable_fontconfig) { version(nanovg_disable_fontconfig) {