gpt4 book ai didi

python - 如何在 rpm-maven-plugin 中禁用 python 预编译?

转载 作者:太空宇宙 更新时间:2023-11-04 03:28:42 32 4
gpt4 key购买 nike

rpm-maven-plugin 生成隐式预编译文件。我不需要这个文件,这个新文件会停止我的 rpm 生成,因为这些文件在我的 rpm 规范中不是自动的。解决方案 https://www.redhat.com/archives/rpm-list/2007-November/msg00020.html不要在我的 Maven 上下文中帮助我!

最佳答案

解决方案是在 pom.xml 中重新定义 __os_install_post 宏:

  <build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>rpm-maven-plugin</artifactId>
<version>2.1-alpha-1</version>
<extensions>true</extensions>
<configuration>
<name>${project.name}</name>
<version>1.1</version>
<release>111</release>
<distribution>Red Hat 6.2 Enterprise Server</distribution>
<group>Application/Media</group>
<defineStatements>
<defineStatement>__os_install_post
/usr/lib/rpm/redhat/brp-compress
%{!?__debug_package:
/usr/lib/rpm/redhat/brp-strip %{__strip}
/usr/lib/rpm/redhat/brp-strip-comment-note %{__strip} %{__objdump}
}
/usr/lib/rpm/redhat/brp-strip-static-archive %{__strip}
/usr/lib/rpm/redhat/brp-python-hardlink
</defineStatement>
</defineStatements>

原始宏是:

 rpm --showrc 

-14: __os_install_post
/usr/lib/rpm/redhat/brp-compress
%{!?__debug_package:/usr/lib/rpm/redhat/brp-strip %{__strip}}
/usr/lib/rpm/redhat/brp-strip-static-archive %{__strip}
/usr/lib/rpm/redhat/brp-strip-comment-note %{__strip} %{__objdump}
/usr/lib/rpm/brp-python-bytecompile
/usr/lib/rpm/redhat/brp-python-hardlink
%{!?__jar_repack:/usr/lib/rpm/redhat/brp-java-repack-jars}
%{nil}

关于python - 如何在 rpm-maven-plugin 中禁用 python 预编译?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32005745/

32 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com