如何将分号传递给 dh_auto_configure

How pass semicolon to dh_auto_configure

我需要将分号分隔的路径列表传递给 cmake,我是这样做的。

dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_PREFIX_PATH=/home/runner/work/ksnip/Qt/5.15.2/gcc_64;/home/runner/work/ksnip/ksnip/tmp -DCMAKE_BUILD_TYPE=Release

但是 dpkg-buildpackage 似乎得到了这个,正如你所看到的,分号后的所有内容都被删除了,第二个路径甚至发布类型都丢失了。

cd obj-x86_64-linux-gnu && cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_SYSCONFDIR=/etc -DCMAKE_INSTALL_LOCALSTATEDIR=/var -DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON -DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON "-GUnix Makefiles" -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_AUTOGEN_VERBOSE=ON -DCMAKE_INSTALL_LIBDIR=lib/x86_64-linux-gnu  -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_PREFIX_PATH=/home/runner/work/ksnip/Qt/5.15.2/gcc_64 ..

有什么办法解决这个问题?

看起来字符串必须像这样引用:

dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_PREFIX_PATH="/home/runner/work/ksnip/Qt/5.15.2/gcc_64;/home/runner/work/ksnip/ksnip/tmp" -DCMAKE_BUILD_TYPE=Release