瀏覽代碼

bison: add more platforms. (#1047)

Chen Yufei 3 年之前
父節點
當前提交
8fd5b5d2cb
共有 1 個文件被更改,包括 10 次插入6 次删除
  1. 10 6
      packages/b/bison/xmake.lua

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

@@ -19,15 +19,19 @@ package("bison")
         add_deps("m4")
         add_deps("m4")
     end
     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")
         package:addenv("PATH", "bin")
     end)
     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)
         import("package.tools.autoconf").install(package)
         os.rm(package:installdir("share", "doc"))
         os.rm(package:installdir("share", "doc"))
     end)
     end)