- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我正在尝试在我的 Windows 机器上创建我的 maven 项目的 .rpm 文件。
我按照以下链接中给出的步骤来实现它。
http://tim-perry.co.uk/blog/2012/11/22/building_rpms_on_windows_with_maven
当我运行命令 mvn package rpm:attached-rpm 它显示构建成功,但没有生成 rpm 文件。相反,它会在目标下创建一个名为“rpm”的目录,并将所有需要的文件(如 pom 中所述)复制到该目录下。
让我知道我在这里错过了什么。
下面是我使用的pom
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd ">
<modelVersion>4.0.0</modelVersion>
<groupId>com.org</groupId>
<artifactId>inv_project</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>inv_project</name>
<url>http://maven.apache.org</url>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>rpm-maven-plugin</artifactId>
<version>2.0-beta-1</version>
<extensions>true</extensions>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>attached-rpm</goal>
</goals>
</execution>
</executions>
<configuration>
<name>PName</name>
<release>1</release>
<copyright></copyright>
<distribution></distribution>
<workarea>target/rpm</workarea>
<group></group>
<mappings>
<mapping>
<directory>/bin/</directory>
<filemode>755</filemode>
<username>user</username>
<groupname>sysop</groupname>
<sources>
<source>
<location>test/</location>
<includes>
<include>*.jar</include>
</includes>
</source>
</sources>
</mapping>
<mapping>
<directory>/conf/</directory>
<filemode>755</filemode>
<username>user</username>
<groupname>sysop</groupname>
<sources>
<source>
<location>src/resources</location>
<includes>
<include>*.properties</include>
</includes>
</source>
</sources>
</mapping>
</mappings>
<postinstallScript />
</configuration>
</plugin>
</plugins>
</build>
</project>
添加日志
[INFO] --- rpm-maven-plugin:2.0-beta-2:attached-rpm (attach-rpm) @ mvi_cmpipe ---
[DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=0, ConflictMarker.markTime=0, ConflictMarker.nodeCount=30, ConflictIdSorter.graphTime=0, ConflictIdSorter.topsortTime=0, ConflictIdSorter.conflictIdCount=13, ConflictIdSorter.conflictIdCycleCount=0, ConflictResolver.totalTime=1, ConflictResolver.conflictItemCount=27, DefaultDependencyCollector.collectTime=14, DefaultDependencyCollector.transformTime=2}
[DEBUG] org.codehaus.mojo:rpm-maven-plugin:jar:2.0-beta-2:
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0:compile
[DEBUG] org.codehaus.plexus:plexus-archiver:jar:1.0-alpha-5:compile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8:compile
[DEBUG] junit:junit:jar:3.8.2:test
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:compile
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.5.7:compile
[DEBUG] org.apache.maven:maven-artifact:jar:2.0:compile
[DEBUG] org.apache.maven:maven-project:jar:2.0:compile
[DEBUG] org.apache.maven:maven-profile:jar:2.0:compile
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0:compile
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.0:compile
[DEBUG] org.apache.maven:maven-model:jar:2.0:compile
[DEBUG] Created new class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2
[DEBUG] Importing foreign packages into class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2
[DEBUG] Imported: < project>com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:1.0-SNAPSHOT
[DEBUG] Populating class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2
[DEBUG] Included: org.codehaus.mojo:rpm-maven-plugin:jar:2.0-beta-2
[DEBUG] Included: org.codehaus.plexus:plexus-archiver:jar:1.0-alpha-5
[DEBUG] Included: org.codehaus.plexus:plexus-utils:jar:1.5.7
[DEBUG] Excluded: org.apache.maven:maven-plugin-api:jar:2.0
[DEBUG] Excluded: org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] Excluded: junit:junit:jar:3.8.2
[DEBUG] Excluded: classworlds:classworlds:jar:1.1-alpha-2
[DEBUG] Excluded: org.apache.maven:maven-artifact:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-project:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-profile:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-artifact-manager:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-repository-metadata:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-model:jar:2.0
[DEBUG] Configuring mojo org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2:attached-rpm from plugin realm ClassRealm[plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2, parent: sun.misc.Launcher$AppClassLoader@33d626a4]
[DEBUG] Configuring mojo 'org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2:attached-rpm' with basic configurator -->
[DEBUG] (f) artifact = com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:pom:1.0-SNAPSHOT
[DEBUG] (f) attachedArtifacts = []
[DEBUG] (f) copyright = 2010, Org Siemens Networks
[DEBUG] (f) distribution = NAC
[DEBUG] (f) group = NAC
[DEBUG] (s) directory = /bin/
[DEBUG] (s) filemode = 755
[DEBUG] (s) username = omc
[DEBUG] (s) groupname = sysop
[DEBUG] (s) location = D:\INV-project\test
[DEBUG] (s) includes = [*.jar]
[DEBUG] (s) sources = [{"D:\INV-project\test" incl:[*.jar]}]
[DEBUG] (s) directory = /conf/
[DEBUG] (s) filemode = 755
[DEBUG] (s) username = omc
[DEBUG] (s) groupname = sysop
[DEBUG] (s) location = D:\INV-project\src\resources
[DEBUG] (s) includes = [*.properties]
[DEBUG] (s) sources = [{"D:\INV-project\src\resources" incl:[*.properties]}]
[DEBUG] (f) mappings = [["/bin/" {%attr(755,omc,sysop)} from [{"D:\INV-project\test" incl:[*.jar]}]], ["/conf/" {%attr(755,omc,sysop)} from [{"D:\INV-project\src\resources" incl:[*.properties]}]]]
[DEBUG] (f) name = ORG-generic_mediations
[DEBUG] (f) project = MavenProject: com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:1.0-SNAPSHOT @ D:\INV-project\pom.xml
[DEBUG] (f) projversion = 1.0-SNAPSHOT
[DEBUG] (f) release = 1
[DEBUG] (f) summary = mvi_cmpipe
[DEBUG] (f) workarea = D:\INV-project\target\rpm
[DEBUG] -- end configuration --
[DEBUG] project version = 1.0-SNAPSHOT
[WARNING] Version string truncated to 1.0
[DEBUG] targetArch = noarch
[INFO] Creating directory D:\INV-project\target\rpm
[INFO] Creating directory D:\INV-project\target\rpm\BUILD
[INFO] Creating directory D:\INV-project\target\rpm\RPMS
[INFO] Creating directory D:\INV-project\target\rpm\SOURCES
[INFO] Creating directory D:\INV-project\target\rpm\SPECS
[INFO] Creating directory D:\INV-project\target\rpm\SRPMS
[INFO] Creating directory D:\INV-project\target\rpm\buildroot
[INFO] Copying 1 files to D:\INV-project\target\rpm\buildroot\bin
[INFO] Copying 1 files to D:\INV-project\target\rpm\buildroot\conf
[INFO] Creating spec file D:\INV-project\target\rpm\SPECS\ORG-generic_mediations.spec
[DEBUG] writing attriute string for directory: /bin/
[DEBUG] writing attriute string for directory: /conf/
[DEBUG] About to execute 'cmd.exe /X /C "rpmbuild -bb --buildroot D:\INV-project\target\rpm\buildroot --define "_topdir D:\INV-project\target\rpm" --target noarch ORG-generic_mediations.spec"'
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SETLOCAL
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>PUSHD .
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Update buildroot path
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>FOR /F "tokens=*" %i in ('cygpath D:\INV-project\target\rpm\buildroot') do SET NEW_BUILDROOT=%i
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_BUILDROOT=/cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm/buildroot
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Update topdir path
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET TOPDIR="_topdir D:\INV-project\target\rpm"
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET TOPDIR=D:\INV-project\target\rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>FOR /F "tokens=*" %i in ('cygpath "D:\INV-project\target\rpm"') do SET NEW_TOPDIR=%i
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_TOPDIR=/cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Replace path in spec-file
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET OLD_PATH=D:\\ORG\\Project\\MVI\\PM\\INV\\Eric3g_LTE\\trunk\\INV\\Install\\inv-project\\target\\rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_PATH=\/cygdrive\/d\/ORG\/Project\/MVI\/PM\/INV\/Eric3g_LTE\/trunk\/INV\/Install\/inv-project\/target\/rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>sed -s -i -e s/D:\\ORG\\Project\\MVI\\PM\\INV\\Eric3g_LTE\\trunk\\INV\\Install\\inv-project\\target\\rpm\\/\/cygdrive\/d\/ORG\/Project\/MVI\/PM\/INV\/Eric3g_LTE\/trunk\/INV\/Install\/inv-project\/target\/rpm\//g ORG-generic_mediations.spec
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Execute rpmbuild
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>bash -c "rpmb -bb --buildroot /cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm/buildroot --define ""_topdir /cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm"" --target "noarch" --define ""_build_name_fmt %{ARCH}/%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}.rpm"" ORG-generic_mediations.spec"
[INFO] Building target platforms: noarch
[INFO] Building for target noarch
[INFO] Processing files: ORG-generic_mediations-1.0-1.noarch
[INFO]
[WARNING] error: No file attributes configured
[WARNING] No file attributes configured
[INFO]
[INFO] RPM build errors:
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>POPD
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>ENDLOCAL
[INFO]
[INFO] --- rpm-maven-plugin:2.0-beta-2:attached-rpm (default-cli) @ mvi_cmpipe ---
[DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=0, ConflictMarker.markTime=0, ConflictMarker.nodeCount=30, ConflictIdSorter.graphTime=1, ConflictIdSorter.topsortTime=0, ConflictIdSorter.conflictIdCount=13, ConflictIdSorter.conflictIdCycleCount=0, ConflictResolver.totalTime=1, ConflictResolver.conflictItemCount=27, DefaultDependencyCollector.collectTime=10, DefaultDependencyCollector.transformTime=2}
[DEBUG] org.codehaus.mojo:rpm-maven-plugin:jar:2.0-beta-2:
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0:compile
[DEBUG] org.codehaus.plexus:plexus-archiver:jar:1.0-alpha-5:compile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8:compile
[DEBUG] junit:junit:jar:3.8.2:test
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:compile
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.5.7:compile
[DEBUG] org.apache.maven:maven-artifact:jar:2.0:compile
[DEBUG] org.apache.maven:maven-project:jar:2.0:compile
[DEBUG] org.apache.maven:maven-profile:jar:2.0:compile
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0:compile
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.0:compile
[DEBUG] org.apache.maven:maven-model:jar:2.0:compile
[DEBUG] Created new class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2--650166454
[DEBUG] Importing foreign packages into class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2--650166454
[DEBUG] Imported: < project>com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:1.0-SNAPSHOT
[DEBUG] Populating class realm plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2--650166454
[DEBUG] Included: org.codehaus.mojo:rpm-maven-plugin:jar:2.0-beta-2
[DEBUG] Included: org.codehaus.plexus:plexus-archiver:jar:1.0-alpha-5
[DEBUG] Included: org.codehaus.plexus:plexus-utils:jar:1.5.7
[DEBUG] Excluded: org.apache.maven:maven-plugin-api:jar:2.0
[DEBUG] Excluded: org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] Excluded: junit:junit:jar:3.8.2
[DEBUG] Excluded: classworlds:classworlds:jar:1.1-alpha-2
[DEBUG] Excluded: org.apache.maven:maven-artifact:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-project:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-profile:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-artifact-manager:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-repository-metadata:jar:2.0
[DEBUG] Excluded: org.apache.maven:maven-model:jar:2.0
[DEBUG] Configuring mojo org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2:attached-rpm from plugin realm ClassRealm[plugin>org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2--650166454, parent: sun.misc.Launcher$AppClassLoader@33d626a4]
[DEBUG] Configuring mojo 'org.codehaus.mojo:rpm-maven-plugin:2.0-beta-2:attached-rpm' with basic configurator -->
[DEBUG] (f) artifact = com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:pom:1.0-SNAPSHOT
[DEBUG] (f) attachedArtifacts = [com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:rpm:rpm:1.0-SNAPSHOT]
[DEBUG] (f) copyright = 2010, Org Siemens Networks
[DEBUG] (f) distribution = NAC
[DEBUG] (f) group = NAC
[DEBUG] (s) directory = /bin/
[DEBUG] (s) filemode = 755
[DEBUG] (s) username = omc
[DEBUG] (s) groupname = sysop
[DEBUG] (s) location = D:\INV-project\test
[DEBUG] (s) includes = [*.jar]
[DEBUG] (s) sources = [{"D:\INV-project\test" incl:[*.jar]}]
[DEBUG] (s) directory = /conf/
[DEBUG] (s) filemode = 755
[DEBUG] (s) username = omc
[DEBUG] (s) groupname = sysop
[DEBUG] (s) location = D:\INV-project\src\resources
[DEBUG] (s) includes = [*.properties]
[DEBUG] (s) sources = [{"D:\INV-project\src\resources" incl:[*.properties]}]
[DEBUG] (f) mappings = [["/bin/" {%attr(755,omc,sysop)} from [{"D:\INV-project\test" incl:[*.jar]}]], ["/conf/" {%attr(755,omc,sysop)} from [{"D:\INV-project\src\resources" incl:[*.properties]}]]]
[DEBUG] (f) name = ORG-generic_mediations
[DEBUG] (f) project = MavenProject: com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:1.0-SNAPSHOT @ D:\INV-project\pom.xml
[DEBUG] (f) projversion = 1.0-SNAPSHOT
[DEBUG] (f) release = 1
[DEBUG] (f) summary = mvi_cmpipe
[DEBUG] (f) workarea = D:\INV-project\target\rpm
[DEBUG] -- end configuration --
[DEBUG] project version = 1.0-SNAPSHOT
[WARNING] Version string truncated to 1.0
[DEBUG] targetArch = noarch
[INFO] Copying 1 files to D:\INV-project\target\rpm\buildroot\bin
[INFO] Copying 1 files to D:\INV-project\target\rpm\buildroot\conf
[INFO] Creating spec file D:\INV-project\target\rpm\SPECS\ORG-generic_mediations.spec
[DEBUG] writing attriute string for directory: /bin/
[DEBUG] writing attriute string for directory: /conf/
[DEBUG] About to execute 'cmd.exe /X /C "rpmbuild -bb --buildroot D:\INV-project\target\rpm\buildroot --define "_topdir D:\INV-project\target\rpm" --target noarch ORG-generic_mediations.spec"'
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SETLOCAL
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>PUSHD .
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Update buildroot path
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>FOR /F "tokens=*" %i in ('cygpath D:\INV-project\target\rpm\buildroot') do SET NEW_BUILDROOT=%i
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_BUILDROOT=/cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm/buildroot
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Update topdir path
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET TOPDIR="_topdir D:\INV-project\target\rpm"
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET TOPDIR=D:\INV-project\target\rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>FOR /F "tokens=*" %i in ('cygpath "D:\INV-project\target\rpm"') do SET NEW_TOPDIR=%i
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_TOPDIR=/cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Replace path in spec-file
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET OLD_PATH=D:\\ORG\\Project\\MVI\\PM\\INV\\Eric3g_LTE\\trunk\\INV\\Install\\inv-project\\target\\rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>SET NEW_PATH=\/cygdrive\/d\/ORG\/Project\/MVI\/PM\/INV\/Eric3g_LTE\/trunk\/INV\/Install\/inv-project\/target\/rpm
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>sed -s -i -e s/D:\\ORG\\Project\\MVI\\PM\\INV\\Eric3g_LTE\\trunk\\INV\\Install\\inv-project\\target\\rpm\\/\/cygdrive\/d\/ORG\/Project\/MVI\/PM\/INV\/Eric3g_LTE\/trunk\/INV\/Install\/inv-project\/target\/rpm\//g ORG-generic_mediations.spec
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>REM Execute rpmbuild
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>bash -c "rpmb -bb --buildroot /cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm/buildroot --define ""_topdir /cygdrive/d/ORG/Project/MVI/PM/INV/Eric3g_LTE/trunk/INV/Install/inv-project/target/rpm"" --target "noarch" --define ""_build_name_fmt %{ARCH}/%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}.rpm"" ORG-generic_mediations.spec"
[INFO] Building target platforms: noarch
[INFO] Building for target noarch
[INFO] Processing files: ORG-generic_mediations-1.0-1.noarch
[INFO]
[INFO]
[WARNING] error: No file attributes configured
[INFO] RPM build errors:
[WARNING] No file attributes configured
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>POPD
[INFO]
[INFO] D:\INV-project\target\rpm\SPECS>ENDLOCAL
[DEBUG] Replacing attached artifact com.Org.oss.INV.cmpipe.routes:mvi_cmpipe:rpm:rpm:1.0-SNAPSHOT. Old path D:\INV-project\target\rpm\RPMS\noarch\ORG-generic_mediations-1.0-1.noarch.rpm, new path D:\INV-project\target\rpm\RPMS\noarch\ORG-generic_mediations-1.0-1.noarch.rpm.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.025 s
[INFO] Finished at: 2014-10-09T19:45:00+05:30
[INFO] Final Memory: 6M/62M
最佳答案
您是否已确认您可以直接通过命令行(即在 Maven 之外)构建 RPM?
如果不是,那么整个讨论就没有实际意义,所以我假设是这样。
在这种情况下,只需将该命令传递给 Maven exec plugin :
<project>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.3.2</version>
<executions>
<execution>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
<configuration>
<executable>rpmbuild</executable>
<workingDirectory>${basedir}</workingDirectory>
<arguments>
<argument>--test</argument>
</arguments>
</configuration>
</plugin>
</plugins>
</build>
</project>
它会完美地模仿您在命令行上所做的一切。
希望对您有所帮助。
关于java - RPM 文件不是使用 Maven rpm 插件生成的,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26278968/
如何检测 RPM 是源 rpm 还是二进制 rpm? 显然我不想依赖文件名。 最佳答案 源 rpm 由 header 中 SOURCEPM 标记的存在定义。如果 rpm 带有 SOURCEPMM 标签
在Linux操作系统中,有一个系统软件包,它的功能类似于Windows里面的“添加/删除程序”,但是功能又比“添加/删除程序”强很多,它就是Red
我正在尝试从一个 RPM 安装中安装多个 RPM。我已将规范文件制作到 %post 部分中,我使用命令安装了另一个 rpm。 %post rm -f /var/lib/rpm/__db.0* r
我正在尝试从一个 RPM 安装中安装多个 RPM。我已将规范文件制作到 %post 部分中,我使用命令安装了另一个 rpm。 %post rm -f /var/lib/rpm/__db.0* r
请指教为什么我找不到我安装的rpm。我尝试通过 rpm -qa | 检查grep 测试(参见安装 rpm 中的示例:)但似乎没有安装 rpm 为什么? 构建 RPM: [root@linux /us
您好,提前感谢任何人可以为这个问题提供的任何答案。 我有一个 RPM,它本质上是一个展开的 WAR 的包装器。在我的服务器上运行 rpm -i myRPM.rpm 这工作得很好,世界上一切都很好。然后
我必须在包含大量 rpm 的目录下执行 rpm -ivh *.rpm。我想忽略一两个特定的 rpm。我该怎么做? 最佳答案 如果他们在文件名中没有空格或换行符(这是我所期望的,对于 rpms),那么最
我正在为 centos 生成 rpm 文件,但是当我尝试在干净的机器上安装它时,它失败了: --> Running transaction check ---> Package grass.x86
如果有的话,设计 RPM 的“正确”方法是什么,以便可以通过 YUM/RPM 并排安装多个版本而不会相互干扰?对于库,正确的答案似乎与 sonames 有关,尽管我找不到任何关于 sonames、符号
正如主题所读,我想知道是否可以在 RPM 规范文件中使所需的包依赖于条件? 例如,如果在安装目标上,请检查 shell 语句,例如主机正在使用绑定(bind)接口(interface) 并且只有当 R
我想将我的 rpm 文件的名称从 oldname-7.x86_64.rpm 更改为 newname-8.x86_64.rpm。我用新名称创建了新的 rpm,但是当我尝试执行 rpm -Uvh newn
我正在尝试构建并签署 RPM。 我在我正在构建的位置创建了我的 .rpmmacro 文件/path/to/macrodir/ 然后我将 --define 与 _topdir 一起使用,指的是/path
我目前正在重命名我的团队正在生产的产品(对变量、服务接口(interface)、类名等进行适当的重构)。对于本练习的 RPM 重命名部分,我被告知使用 obsoletes 标记。我现在处于错误修复阶段
这个问题很容易表现出来: rpm --eval "%define xyz" error: Macro %xyz has empty body 我想获得 patch_level 和 echo_dist
我需要构建一个 RPM,其唯一目的是安装一些字体。我已经阅读了几个关于此的教程,但是每个人似乎都提出了不同的建议,而且我无法找到类似非常基本的设置来做到这一点。 是否可以只引用 %files 中的文件
我正在升级我们的项目 RPM。问题是当我从 projectname-1.0-0 升级到 projectname-1.0-1 时,它首先安装新项目并卸载旧项目,总的来说,这完全删除了我的项目。我在升级时
我只想创建一个 RPM 文件来分发我的 Linux 二进制文件“foobar”,只有几个依赖项。它有一个配置文件/etc/foobar.conf 并应安装在/usr/bin/foobar 中。 不幸的
我正在尝试记录我的 rpm 完成的事件,但无法找到方法来执行此操作。我正在寻找某种方法来通过规范文件本身来完成此操作。如果我的 rpm 执行 5 个步骤,我需要一种方法将这些步骤及其结果记录到日志中。
如何在 RPM 规范中定义变量?我要在 RPM 中创建 14 个文件夹,并且是通过以下命令创建的: mkdir -p /opt/{Folder,Names,Are,Pretty,Cumbersome}
机器 1 #uname -r Machine 1:3.2.45-0.6.wd.561.41.269.metal1.x86_64 #rpmbuild --version RPM version 4.8.
我是一名优秀的程序员,十分优秀!