add libxtst (#129)

pull/131/head
ruki 4 years ago committed by GitHub
parent 30e420c5b5
commit 3b8e500d30
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      .github/workflows/mingw_macos.yml
  2. 22
      packages/g/gnu-sed/xmake.lua
  3. 4
      packages/l/libx11/xmake.lua
  4. 25
      packages/l/libxtst/xmake.lua

@ -25,5 +25,5 @@ jobs:
- name: Tests
run: |
xmake l ./scripts/test.lua -D -k ${{ matrix.kind }}
xmake l ./scripts/test.lua -D -p mingw -k ${{ matrix.kind }}

@ -0,0 +1,22 @@
package("gnu-sed")
set_kind("binary")
set_homepage("https://www.gnu.org/software/sed/")
set_description("GNU implementation of the famous stream editor.")
set_license("GPL-3.0")
set_urls("https://ftp.gnu.org/gnu/sed/sed-$(version).tar.xz",
"https://ftpmirror.gnu.org/sed/sed-$(version).tar.xz")
add_versions("4.8", "f79b0cfea71b37a8eeec8490db6c5f7ae7719c35587f21edb0617f370eeff633")
on_install("macosx", "linux", function (package)
local configs = {"--disable-dependency-tracking"}
import("package.tools.autoconf").install(package, configs)
end)
on_test(function (package)
os.vrun("sed --version")
io.writefile("test.txt", "Hello world!")
os.vrunv("sed", {"-i", "s/world/World/g", "test.txt"})
assert(io.readfile("test.txt") == "Hello World!")
end)

@ -9,6 +9,10 @@ package("libx11")
if is_plat("macosx", "linux") then
add_deps("pkg-config", "util-macros", "xtrans", "libxcb", "xorgproto")
end
if is_plat("macosx") then
-- fix sed: RE error: illegal byte sequence
add_deps("gnu-sed")
end
on_install("macosx", "linux", function (package)
local configs = {"--sysconfdir=" .. package:installdir("etc"),

@ -0,0 +1,25 @@
package("libxtst")
set_homepage("https://www.x.org/")
set_description("X.Org: Client API for the XTEST & RECORD extensions")
set_license("MIT")
set_urls("https://www.x.org/archive/individual/lib/libXtst-$(version).tar.bz2")
add_versions("1.2.3", "4655498a1b8e844e3d6f21f3b2c4e2b571effb5fd83199d428a6ba7ea4bf5204")
if is_plat("macosx", "linux") then
add_deps("pkg-config", "util-macros", "libxi", "xorgproto")
end
on_install("macosx", "linux", function (package)
local configs = {"--sysconfdir=" .. package:installdir("etc"),
"--localstatedir=" .. package:installdir("var"),
"--disable-dependency-tracking",
"--disable-silent-rules",
"--enable-specs=no"}
import("package.tools.autoconf").install(package, configs)
end)
on_test(function (package)
assert(package:has_ctypes("XRecordRange8", {includes = {"X11/Xlib.h", "X11/extensions/record.h"}}))
end)
Loading…
Cancel
Save