Browse Source

bison: add more platforms. (#1047)

Chen Yufei 3 years ago
parent
commit
8fd5b5d2cb
1 changed files with 10 additions and 6 deletions
  1. 10 6
      packages/b/bison/xmake.lua

+ 10 - 6
packages/b/bison/xmake.lua

@@ -19,15 +19,19 @@ package("bison")
         add_deps("m4")
     end
 
-    on_load("macosx", "linux", "bsd", function (package)
+    on_load(function (package)
+        if package:is_plat("windows") then
+            -- handled by winflexbison
+            return
+        end
         package:addenv("PATH", "bin")
     end)
 
-    on_install("windows", function (package)
-        -- handled by winflexbison
-    end)
-
-    on_install("macosx", "linux", "bsd", function (package)
+    on_install(function (package)
+        if package:is_plat("windows") then
+            -- handled by winflexbison
+            return
+        end
         import("package.tools.autoconf").install(package)
         os.rm(package:installdir("share", "doc"))
     end)