mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-15 22:12:20 +00:00
Meta: Fix building skia on FreeBSD
This commit is contained in:
parent
515a94c49d
commit
f0cdf0e9b5
Notes:
github-actions[bot]
2025-07-15 19:47:09 +00:00
Author: https://github.com/cqundefine
Commit: f0cdf0e9b5
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5244
Reviewed-by: https://github.com/ADKaster ✅
Reviewed-by: https://github.com/clausecker
Reviewed-by: https://github.com/trflynn89
2 changed files with 35 additions and 0 deletions
28
Meta/CMake/vcpkg/overlay-ports/skia/fix-freebsd.patch
Normal file
28
Meta/CMake/vcpkg/overlay-ports/skia/fix-freebsd.patch
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
diff --git a/BUILD.gn b/BUILD.gn
|
||||||
|
index 72d9a23..9c0532e 100644
|
||||||
|
--- a/BUILD.gn
|
||||||
|
+++ b/BUILD.gn
|
||||||
|
@@ -26,7 +26,8 @@ import("gn/ios.gni")
|
||||||
|
|
||||||
|
# Skia public API, generally provided by :skia.
|
||||||
|
config("skia_public") {
|
||||||
|
- include_dirs = [ "." ]
|
||||||
|
+ include_dirs = [ ".", "/usr/local/include" ]
|
||||||
|
+ lib_dirs = [ "/usr/local/lib" ]
|
||||||
|
|
||||||
|
defines = [
|
||||||
|
"SK_CODEC_DECODES_BMP",
|
||||||
|
diff --git a/gn/toolchain/BUILD.gn b/gn/toolchain/BUILD.gn
|
||||||
|
index 85858b5..8d6a0ae 100644
|
||||||
|
--- a/gn/toolchain/BUILD.gn
|
||||||
|
+++ b/gn/toolchain/BUILD.gn
|
||||||
|
@@ -315,7 +315,7 @@ template("gcc_like_toolchain") {
|
||||||
|
rspfile = "{{output}}.rsp"
|
||||||
|
rspfile_content = "{{inputs}}"
|
||||||
|
rm_py = rebase_path("../rm.py")
|
||||||
|
- command = "$shell python3 \"$rm_py\" \"{{output}}\" && $ar rcs {{output}} @$rspfile"
|
||||||
|
+ command = "$shell python3 \"$rm_py\" \"{{output}}\" && $ar rcs {{output}} `cat $rspfile`"
|
||||||
|
}
|
||||||
|
|
||||||
|
outputs =
|
||||||
|
|
|
@ -14,6 +14,7 @@ vcpkg_from_github(
|
||||||
vulkan-headers.patch
|
vulkan-headers.patch
|
||||||
pdfsubsetfont-uwp.diff
|
pdfsubsetfont-uwp.diff
|
||||||
skparagraph-gni.diff
|
skparagraph-gni.diff
|
||||||
|
fix-freebsd.patch
|
||||||
)
|
)
|
||||||
|
|
||||||
# De-vendor
|
# De-vendor
|
||||||
|
@ -123,6 +124,8 @@ elseif(VCPKG_TARGET_IS_WINDOWS)
|
||||||
string(APPEND OPTIONS " skia_enable_skparagraph=false")
|
string(APPEND OPTIONS " skia_enable_skparagraph=false")
|
||||||
string(APPEND OPTIONS " skia_enable_bentleyottmann=false")
|
string(APPEND OPTIONS " skia_enable_bentleyottmann=false")
|
||||||
endif()
|
endif()
|
||||||
|
elseif(VCPKG_TARGET_IS_FREEBSD)
|
||||||
|
string(APPEND OPTIONS " target_os=\"linux\"")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
|
||||||
|
@ -131,6 +134,10 @@ else()
|
||||||
string(APPEND OPTIONS " is_component_build=false")
|
string(APPEND OPTIONS " is_component_build=false")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(VCPKG_TARGET_IS_FREEBSD)
|
||||||
|
string(APPEND OPTIONS " skia_use_dng_sdk=false")
|
||||||
|
endif()
|
||||||
|
|
||||||
set(required_externals
|
set(required_externals
|
||||||
dng_sdk
|
dng_sdk
|
||||||
expat
|
expat
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue