Macos mac:如何使用--component选项将License.txt添加到使用productbuild构建的pkg中?
目前,我们使用productbuild--component将mac安装程序构建为一个pkg文件(见以下帖子:) 这工作非常好,但我也希望添加一个许可证文件到这个安装程序 使用packagemaker,您可以指定选项--resources[path\u to\u resources\u file]。如果将License.txt放入指定的resources文件夹中,安装程序会神奇地包含一个License步骤 虽然productbuild的手册页也描述了一个--resources选项,但实际上它似乎不适用于--component选项。它似乎完全忽略了这个选项 根据productbuild手册页,--component选项显然只接受产品定义plist(我查看了plist选项,没有一个选项适用于许可证文件)、组件、可选安装路径和输出路径。尽管--sign选项也可以工作 有人知道在使用productbuild--component时是否可能(如果可能,如何)包含安装程序的许可证文件吗 提前谢谢Macos mac:如何使用--component选项将License.txt添加到使用productbuild构建的pkg中?,macos,installation,licensing,productbuild,Macos,Installation,Licensing,Productbuild,目前,我们使用productbuild--component将mac安装程序构建为一个pkg文件(见以下帖子:) 这工作非常好,但我也希望添加一个许可证文件到这个安装程序 使用packagemaker,您可以指定选项--resources[path\u to\u resources\u file]。如果将License.txt放入指定的resources文件夹中,安装程序会神奇地包含一个License步骤 虽然productbuild的手册页也描述了一个--resources选项,但实际上它似乎
i在作为参数传递给productbuild的分发文件中,包括许可证元素,如下所示:
<?xml version="1.0" encoding="utf-8"?>
<installer-gui-script minSpecVersion="1">
<title>My Awesome App</title>
<welcome file="welcome.html" />
<readme file="readme.html" />
<license file="license.html" />
<conclusion file="conclusion.html" />
<options customize="never" />
<choices-outline>
<line choice="install"/>
</choices-outline>
<choice id="install" visible="true" title="Install" description="Installation description goes here">
<pkg-ref id="com.prosc.RemoteExecution.install.pkg">#installer.pkg</pkg-ref>
</choice>
</installer-gui-script>
productbuild --distribution distribution.xml --resources building/ "Mac Installer.pkg"