浏览代码

Plugin: do not overwrite define value for -lib

Yuxiao Mao 2 月之前
父节点
当前提交
3aeaf15cf6
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 2 1
      hide/Plugin.hx

+ 2 - 1
hide/Plugin.hx

@@ -84,7 +84,8 @@ class Plugin {
 					if( !Context.defined("hxnodejs") ) Context.error("Please add -lib hxnodejs", Context.currentPos());
 					if( !Context.defined("hxnodejs") ) Context.error("Please add -lib hxnodejs", Context.currentPos());
 					continue;
 					continue;
 				}
 				}
-				C.define(value,"1");
+				if( !Context.defined(value) )
+					C.define(value,"1");
 				C.addClassPath(getLibraryPath(value));
 				C.addClassPath(getLibraryPath(value));
 			case "-D":
 			case "-D":
 				C.define(value,"1");
 				C.define(value,"1");