|
@@ -3,11 +3,12 @@ package("libxaw")
|
|
set_homepage("https://gitlab.freedesktop.org/xorg/lib/libxaw")
|
|
set_homepage("https://gitlab.freedesktop.org/xorg/lib/libxaw")
|
|
set_description("X.Org: X Athena Widget Set")
|
|
set_description("X.Org: X Athena Widget Set")
|
|
|
|
|
|
- set_urls("https://www.x.org/archive/individual/lib/libXaw-$(version).tar.bz2")
|
|
|
|
- add_versions("1.0.14", "76aef98ea3df92615faec28004b5ce4e5c6855e716fa16de40c32030722a6f8e")
|
|
|
|
|
|
+ set_urls("https://www.x.org/archive/individual/lib/libXaw-$(version).tar.gz")
|
|
|
|
+ add_versions("1.0.14", "59cfed2712cc80bbfe62dd1aacf24f58d74a76dd08329a922077b134a8d8048f")
|
|
|
|
+ add_versions("1.0.16", "012f90adf8739f2f023d63a5fee1528949cf2aba92ef7ac1abcfc2ae9cf28798")
|
|
|
|
|
|
if is_plat("macosx", "linux") then
|
|
if is_plat("macosx", "linux") then
|
|
- add_deps("libxmu", "libxpm")
|
|
|
|
|
|
+ add_deps("libxmu", "libxpm", "libx11", "libxt", "libxext", "libice", "libsm")
|
|
end
|
|
end
|
|
|
|
|
|
if is_plat("linux") then
|
|
if is_plat("linux") then
|
|
@@ -15,7 +16,33 @@ package("libxaw")
|
|
end
|
|
end
|
|
|
|
|
|
on_install("macosx", "linux", function (package)
|
|
on_install("macosx", "linux", function (package)
|
|
- import("package.tools.autoconf").install(package)
|
|
|
|
|
|
+ local configs = {"--sysconfdir=" .. package:installdir("etc"),
|
|
|
|
+ "--localstatedir=" .. package:installdir("var"),
|
|
|
|
+ "--disable-dependency-tracking",
|
|
|
|
+ "--disable-silent-rules",
|
|
|
|
+ "--disable-specs"}
|
|
|
|
+ -- fix undefined reference on macOS
|
|
|
|
+ if package:is_plat("macosx") then
|
|
|
|
+ local cflags = {}
|
|
|
|
+ local ldflags = {}
|
|
|
|
+ for _, dep in ipairs(package:orderdeps()) do
|
|
|
|
+ local fetchinfo = dep:fetch()
|
|
|
|
+ if fetchinfo then
|
|
|
|
+ for _, includedir in ipairs(fetchinfo.includedirs or fetchinfo.sysincludedirs) do
|
|
|
|
+ table.insert(cflags, "-I" .. includedir)
|
|
|
|
+ end
|
|
|
|
+ for _, linkdir in ipairs(fetchinfo.linkdirs) do
|
|
|
|
+ table.insert(ldflags, "-L" .. linkdir)
|
|
|
|
+ end
|
|
|
|
+ for _, link in ipairs(fetchinfo.links) do
|
|
|
|
+ table.insert(ldflags, "-l" .. link)
|
|
|
|
+ end
|
|
|
|
+ end
|
|
|
|
+ end
|
|
|
|
+ import("package.tools.autoconf").install(package, configs, {cflags = cflags, ldflags = ldflags})
|
|
|
|
+ else
|
|
|
|
+ import("package.tools.autoconf").install(package, configs)
|
|
|
|
+ end
|
|
end)
|
|
end)
|
|
|
|
|
|
on_test(function (package)
|
|
on_test(function (package)
|