Browse Source

hwdata: update and opti (#8134)

* opti

* fix(ci): get ginstall(gnu install) for freebsd

* update to v0.399
Willaaaaaaa 2 ngày trước cách đây
mục cha
commit
7b146e6669

+ 1 - 1
.github/workflows/freebsd.yml

@@ -28,7 +28,7 @@ jobs:
           sync: sshfs
           mem: 12288
           copyback: false
-          prepare: pkg install -y git curl unzip gmake llvm gsed bash perl5 openssl 7-zip
+          prepare: pkg install -y git curl unzip gmake llvm gsed bash perl5 openssl 7-zip coreutils
           run: |
             git config --global --add safe.directory `pwd`
             git clone --recurse-submodules https://github.com/xmake-io/xmake.git /tmp/xmake -b dev

+ 0 - 15
packages/h/hwdata/patches/v0.397/bsd-makefile.patch

@@ -1,15 +0,0 @@
-diff --git a/Makefile b/Makefile
-index 905b082..0ac40fa 100644
---- a/Makefile
-+++ b/Makefile
-@@ -45,10 +45,6 @@ install: Makefile.inc hwdata.pc
- 	for foo in $(IDFILES) ; do \
- 		install -m 644 $$foo $(DESTDIR)$(datadir)/$(NAME) ;\
- 	done
--	@if [ "$(blacklist)" = true ]; then \
--		mkdir -p -m 755 $(DESTDIR)$(libdir)/modprobe.d ;\
--		install -m 644 -T blacklist.conf $(DESTDIR)$(libdir)/modprobe.d/dist-blacklist.conf ;\
--	fi;
- 	mkdir -p -m 755 $(DESTDIR)$(datadir)/pkgconfig
- 	install -m 644 hwdata.pc $(DESTDIR)$(datadir)/pkgconfig/
- 

+ 4 - 4
packages/h/hwdata/xmake.lua

@@ -7,13 +7,13 @@ package("hwdata")
     add_urls("https://github.com/vcrhonek/hwdata/archive/refs/tags/$(version).tar.gz",
              "https://github.com/vcrhonek/hwdata.git")
 
+    add_versions("v0.399", "74872355e14d5ddc48a0f63036227ffb5f7796a3012c6377ac1fc7432ffe2b41")
     add_versions("v0.397", "09eee39e73a63ab27af651ab6afdd13d6e5c3485872f2cd406b35e4d80ffdb0b")
 
-    if is_plat("bsd") then
-        add_patches("v0.397", "patches/v0.397/bsd-makefile.patch", "d14efe1d4727fc6ec4365c0fab10688c83a314776caa8575a61bb0287e92b2c9")
-    end
-
     on_install("linux", "bsd", function (package)
+        if package:is_plat("bsd") then
+            io.replace("Makefile", "install -m 644", "ginstall -m 644", {plain = true})
+        end
         import("package.tools.autoconf").install(package)
     end)