【发布时间】:2020-06-02 21:50:39
【问题描述】:
我正在使用我的 linux 机器在家庭办公室工作, 肯定会写出可移植的代码。 使用shell和gnumake,通过
编译javajavac -Xlint:deprecation -Xlint:unchecked --module-path libs/nrjavaserial-4.0.1.jar:libs/jep-3.9.0.jar:libs/commons-beanutils-1.9.4.jar:libs/commons-collections-3.2.2.jar:libs/commons-logging-1.2.jar:src/ src/main/de/name/product/Product.java -d target/classes/
一切正常。 现在在办公室使用 Windows 10 但仍然 gnumake,无法正常工作。 同样来自 git bash,没有。
我会满足于让它在 gitshell 中运行的第一步。
我使用javac 11.0.7 和2.26.0.windows.1。
错误(由于与客户有关,我无法完整显示) 表明没有 jar 被接受:
error: cannot find symbol
NRSerialPort serial = getSingleSerialPort(baudRate);
^
symbol: class NRSerialPort
location: class xxx
表明libs/nrjavaserial-4.0.1.jar 虽然存在但不被接受
和
error: cannot find symbol
} catch(JepException e) {
^
symbol: class JepException
location: class XXX
表示不接受libs/jep-3.9.0.jar。
请注意,在 linux 上,在普通的 bash shell 上一切正常。
Windows 的分隔符可能错误? 我一直在想,分隔符在 git bash 上是透明的吗? 或只有/但不是:? 我尝试了几种组合,但没有成功。
我怀疑一切都很容易……对吧?
【问题讨论】:
-
你是对的。我会编辑