質問

RPM-Maven-Pluginの助けを借りてRPMパッケージを作成しようとしています。

%前のスクリプトレット(またはその問題のための任意のスクリプトレット)を生成しようとするまで、すべてがうまくいきます。

pom.xml抜粋は次のとおりです。

<plugin>
    <groupId>org.codehaus.mojo</groupId>
    <artifactId>rpm-maven-plugin</artifactId>
    <version>2.0-beta-2</version>
    <executions>
        <execution>
            <goals>
                <goal>attached-rpm</goal>
            </goals>
        </execution>
    </executions>
    <configuration>
        <copyright>Copyright 2010 XXX, Inc. All rights reserved</copyright>
        <vendor>XXX, Inc.</vendor>
        <group>Applications/System</group>
        <packager>${env.USER}</packager>
        <needarch>true</needarch>
        <prefix>/usr/xxx</prefix>
        <mappings></mappings>

        <preinstallScriptlet>
            <script>echo "installing now"</script>
        </preinstallScriptlet>
    </configuration>
</plugin>

...そして、生成された仕様ファイルは次のとおりです。

Name: Server
Version: 1.0.0.0
Release: 01_1
Summary: Server Maven Webapp
License: Copyright 2010 XXX, Inc. All rights reserved
Vendor: XXX, Inc.
Group: Applications/System
Packager: yaneeve
Prefix: /usr/xxx
BuildRoot: ....../target/rpm/buildroot

%description
Server

%files

注:マッピングタグは関連するマッピングを生成しますが、明確な目的でここで削除されています。いずれにせよ、サイプトレットは生成されません。

入力はありますか?

皆さんありがとう

編集1:

Maven 2と3の両方で構築された結果は同じです。

役に立ちましたか?

解決

プラグインバージョンの問題のようです...

2.0ベータ-2の代わりに、スクリプトレットをサポートするために必要なバージョンは 2.1-alpha-1

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top