[Jpackage-commits] dist/commons-build-plugin/JPP-6 Makefile, NONE, 1.1 commons-build-plugin-jpp-depmap.xml, NONE, 1.1 commons-build-plugin-settings.xml, NONE, 1.1 commons-build-plugin.spec, NONE, 1.1 sources, NONE, 1.1

jpackage jpackage at ryu.zarb.org
Mon Dec 6 00:19:48 CET 2010


Update of /home/projects/jpackage/cvs/dist/commons-build-plugin/JPP-6
In directory ryu.zarb.org:/tmp/cvs-serv20236/JPP-6

Added Files:
	Makefile commons-build-plugin-jpp-depmap.xml 
	commons-build-plugin-settings.xml commons-build-plugin.spec 
	sources 
Log Message:
Import commons-build-plugin into JPP-6

--- NEW FILE: sources ---
58f674c9e5d9bcde33fe9d86b0fa5403  commons-build-plugin-1.2.tar.gz

--- NEW FILE: commons-build-plugin.spec ---
# Copyright (c) 2000-2010, JPackage Project
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# 1. Redistributions of source code must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
#    notice, this list of conditions and the following disclaimer in the
#    documentation and/or other materials provided with the
#    distribution.
# 3. Neither the name of the JPackage Project nor the names of its
#    contributors may be used to endorse or promote products derived
#    from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#

%define section         free

Name:           commons-build-plugin
Version:        1.2
Release:        1%{?dist}
Epoch:          0
Summary:        Apache Commons Build Plugin
License:        Apache Software License 2.0
Url:            http://commons.apache.org/
Group:          Development/Libraries/Java
Source0:        %{name}-%{version}.tar.gz
# svn export http://svn.apache.org/repos/asf/commons/proper/commons-build-plugin/tags/commons-build-plugin-1.2

Source1:        %{name}-settings.xml
Source2:        %{name}-jpp-depmap.xml


BuildRequires:  jpackage-utils >= 0:1.7.5
BuildRequires:  java-devel >= 0:1.6.0
BuildRequires:  ant >= 0:1.7.1
BuildRequires:  junit >= 0:3.8.2

BuildRequires:  maven2 >= 2.0.8
BuildRequires:  maven2-default-skin
BuildRequires:  maven2-plugin-antrun
BuildRequires:  maven2-plugin-assembly
BuildRequires:  maven2-plugin-compiler
BuildRequires:  maven2-plugin-idea
BuildRequires:  maven2-plugin-install
BuildRequires:  maven2-plugin-jar
BuildRequires:  maven2-plugin-javadoc
BuildRequires:  maven2-plugin-plugin
BuildRequires:  maven2-plugin-project-info-reports
BuildRequires:  maven2-plugin-resources
BuildRequires:  maven2-plugin-site
BuildRequires:  maven-release
BuildRequires:  maven-shared-plugin-tools-ant
BuildRequires:  maven-surefire-plugin
BuildRequires:  maven-surefire-report-plugin
BuildRequires:  mojo-maven2-plugin-jdepend
BuildRequires:  apache-commons-parent

Requires(post):    jpackage-utils >= 0:1.7.5
Requires(postun):  jpackage-utils >= 0:1.7.5
BuildArch:      noarch

BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot

%description
This is a Maven 2.x Ant Plugin which is used by 
Apache Commons builds. 

%prep
%setup -q 
cp %{SOURCE1} settings.xml

%build
sed -i -e "s|<url>__JPP_URL_PLACEHOLDER__</url>|<url>file://`pwd`/.m2/repository</url>|g" settings.xml
sed -i -e "s|<url>__JAVADIR_PLACEHOLDER__</url>|<url>file://`pwd`/external_repo</url>|g" settings.xml
sed -i -e "s|<url>__MAVENREPO_DIR_PLACEHOLDER__</url>|<url>file://`pwd`/.m2/repository</url>|g" settings.xml
sed -i -e "s|<url>__MAVENDIR_PLUGIN_PLACEHOLDER__</url>|<url>file:///usr/share/maven2/plugins</url>|g" settings.xml
sed -i -e "s|<url>__ECLIPSEDIR_PLUGIN_PLACEHOLDER__</url>|<url>file:///usr/share/eclipse/plugins</url>|g" settings.xml

export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository
#mkdir -p $MAVEN_REPO_LOCAL/JPP/maven2/poms
#cp %{SOURCE3} $MAVEN_REPO_LOCAL/JPP/maven2/poms/JPP-jakarta-commons-parent.pom

mkdir external_repo
ln -s %{_javadir} external_repo/JPP

mvn-jpp \
        -e \
        -s $(pwd)/settings.xml \
        -Dmaven2.jpp.depmap.file=%{SOURCE2} \
        -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
        install

mvn-jpp \
        -e \
        -s $(pwd)/settings.xml \
        -Dmaven2.jpp.depmap.file=%{SOURCE2} \
        -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
        site

%install
rm -rf $RPM_BUILD_ROOT
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
install -m 644 target/%{name}-%{version}.jar \
               $RPM_BUILD_ROOT%{_javadir}/%{name}-%{version}.jar
(cd $RPM_BUILD_ROOT%{_javadir} && for jar in *-%{version}.jar; do ln -sf ${jar} `echo $jar| sed  "s|-%{version}||g"`; done)

# poms
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/maven2/poms
install -m 644 pom.xml \
    $RPM_BUILD_ROOT%{_datadir}/maven2/poms/JPP-%{name}.pom
%add_to_maven_depmap org.apache.commons %{name} %{version} JPP %{name}

%clean
rm -rf $RPM_BUILD_ROOT

%post
%update_maven_depmap

%postun
%update_maven_depmap 

%files
%defattr(0644,root,root,0755)
%{_javadir}/*.jar
%{_datadir}/maven2/poms/*
%{_mavendepmapfragdir}/*
%doc target/site

%changelog
* Sun Dec 05 2010 Ralph Apel <r.apel at r-apel.de> 0:1.2-1
- 1.2

* Wed May 06 2009 Ralph Apel <r.apel at r-apel.de> 0:1.1-1.jpp5
- First release


--- NEW FILE: Makefile ---
# Makefile for source rpm: commons-build-plugin
# $Id: Makefile,v 1.1 2010/12/05 23:19:45 jpackage Exp $
NAME := commons-build-plugin
SPECFILE = $(firstword $(wildcard *.spec))

define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef

MAKEFILE_COMMON := $(shell $(find-makefile-common))

ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef

MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif

include $(MAKEFILE_COMMON)

--- NEW FILE: commons-build-plugin-jpp-depmap.xml ---
<dependencies>
<!--
  <dependency>
    <maven>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>3.8.2</version>
    </maven>
    <jpp>
      <groupId>JPP</groupId>
      <artifactId>junit</artifactId>
      <version>3.8.2</version>
    </jpp>
  </dependency>
  <dependency>
    <maven>
      <groupId>xmlunit</groupId>
      <artifactId>xmlunit</artifactId>
      <version>1.0</version>
    </maven>
    <jpp>
      <groupId>JPP</groupId>
      <artifactId>xmlunit</artifactId>
      <version>1.0</version>
    </jpp>
  </dependency>
  <dependency>
    <maven>
      <groupId>xmlunit</groupId>
      <artifactId>xmlunit</artifactId>
      <version>1.0</version>
    </maven>
    <jpp>
      <groupId>JPP</groupId>
      <artifactId>xmlunit</artifactId>
      <version>1.0</version>
    </jpp>
  </dependency>
-->
  <dependency>
    <maven>
      <groupId>xmlpull</groupId>
      <artifactId>xmlpull</artifactId>
      <version>1.1.3.1</version>
    </maven>
    <jpp>
      <groupId>JPP</groupId>
      <artifactId>xpp3</artifactId>
      <version>1.1.3.8</version>
    </jpp>
  </dependency>

</dependencies>

--- NEW FILE: commons-build-plugin-settings.xml ---
<settings>
	<profiles>
		<profile>
			<id>JPP</id>
			<repositories>
				<repository>
					<id>internal</id>
					<layout>jpp</layout>
					<url>__JPP_URL_PLACEHOLDER__</url>
				</repository>
				<repository>
					<id>external</id>
					<layout>jpp</layout>
					<url>__JAVADIR_PLACEHOLDER__</url>
				</repository>
				<repository>
					<id>local</id>
					<layout>jpp</layout>
					<url>__MAVENREPO_DIR_PLACEHOLDER__</url>
				</repository>
			</repositories>
			<pluginRepositories>
				<pluginRepository>
					<id>plugins-internal</id>
					<name>plugins-internal</name>
					<layout>jpp</layout>
					<url>__JPP_URL_PLACEHOLDER__</url>
				</pluginRepository>
				<pluginRepository>
					<id>plugins-external</id>
					<name>plugins-external</name>
					<layout>jpp</layout>
					<url>__JAVADIR_PLACEHOLDER__</url>
				</pluginRepository>
				<pluginRepository>
					<id>plugins-maven</id>
					<name>plugins-maven</name>
					<layout>jpp</layout>
					<url>__MAVENDIR_PLUGIN_PLACEHOLDER__</url>
				</pluginRepository>
			</pluginRepositories>
		</profile>
	</profiles>
	<activeProfiles>
		<activeProfile>JPP</activeProfile>
	</activeProfiles>
</settings>




More information about the JPackage-commits mailing list