remove `*_static` option for `gdal` (#4320)

pull/4322/head
zjyhjqs 6 months ago committed by GitHub
parent dac0fef123
commit e3ea284a14
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 10
      packages/g/gdal/xmake.lua

@ -11,7 +11,6 @@ package("gdal")
add_deps("cmake")
add_configs("apps", {description = "Build GDAL applications.", default = false, type = "boolean"})
add_configs("curl", {description = "Use CURL.", default = false, type = "boolean"})
add_configs("curl_static", {description = "Use static build of CURL.", default = false, type = "boolean"})
add_configs("geos", {description = "Use GEOS.", default = false, type = "boolean"})
add_configs("gif", {description = "Use GIF.", default = false, type = "boolean"})
add_configs("iconv", {description = "Use Iconv.", default = false, type = "boolean"})
@ -31,7 +30,6 @@ package("gdal")
local configdeps = {
curl = "libcurl",
curl_static = "libcurl",
geos = "geos",
gif = "giflib",
iconv = "libiconv",
@ -45,13 +43,9 @@ package("gdal")
for name, dep in pairs(configdeps) do
if package:config(name) then
if name:match('^(.*)_static$') then
package:add("deps", dep, {configs = {shared = false}})
else
package:add("deps", dep)
end
end
end
end)
on_install("windows|x86", "windows|x64", "macosx", "linux", function (package)
@ -65,11 +59,11 @@ package("gdal")
table.insert(configs, "-DBUILD_APPS=" .. (package:config("apps") and "ON" or "OFF"))
local packagedeps = {"proj"}
if package:config("curl") or package:config("curl_static") then
if package:config("curl") then
table.insert(packagedeps, "libcurl")
table.insert(configs, "-DGDAL_USE_CURL=ON")
if package:config("curl_static") then
if not package:dep("libcurl"):config("shared") then
table.insert(configs, "-DCURL_USE_STATIC_LIBS=ON")
end
end

Loading…
Cancel
Save