This commit is contained in:
parent
8a6f07f819
commit
b156b66e7f
3
parboiled-1.1.6-build.tar.xz
Normal file
3
parboiled-1.1.6-build.tar.xz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:abf6c8f76c4bad243e1a4cba7339cb605d732b08113e225dbcedbb0684e921c4
|
||||
size 2692
|
@ -1,95 +0,0 @@
|
||||
--- parboiled-scala/pom.xml 2013-08-26 12:54:13.000000000 +0200
|
||||
+++ parboiled-scala/pom.xml-gil 2014-03-20 07:40:12.564265870 +0100
|
||||
@@ -54,4 +54,91 @@
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
+ <build>
|
||||
+ <plugins>
|
||||
+ <plugin>
|
||||
+ <groupId>org.apache.maven.plugins</groupId>
|
||||
+ <artifactId>maven-antrun-plugin</artifactId>
|
||||
+ <version>1.7</version>
|
||||
+ <executions>
|
||||
+ <execution>
|
||||
+ <id>scala-compile</id>
|
||||
+ <phase>compile</phase>
|
||||
+ <configuration>
|
||||
+ <tasks>
|
||||
+ <property name="build.compiler" value="extJavac"/>
|
||||
+ <taskdef resource="scala/tools/ant/antlib.xml" classpathref="maven.compile.classpath"/>
|
||||
+ <mkdir dir="${project.build.outputDirectory}"/>
|
||||
+ <scalac srcdir="src/main" destdir="${project.build.outputDirectory}" classpathref="maven.compile.classpath">
|
||||
+ <include name="scala/**/*.scala"/>
|
||||
+ </scalac>
|
||||
+ </tasks>
|
||||
+ </configuration>
|
||||
+ <goals>
|
||||
+ <goal>run</goal>
|
||||
+ </goals>
|
||||
+ </execution>
|
||||
+ <!--TODO unavailable test deps-->
|
||||
+ <!--execution>
|
||||
+ <id>scala-test-compile</id>
|
||||
+ <phase>test-compile</phase>
|
||||
+ <configuration>
|
||||
+ <tasks>
|
||||
+ <property name="build.compiler" value="extJavac"/>
|
||||
+ <taskdef resource="scala/tools/ant/antlib.xml" classpathref="maven.compile.classpath"/>
|
||||
+ <mkdir dir="${project.build.testOutputDirectory}"/>
|
||||
+ <scalac srcdir="src/test" destdir="${project.build.testOutputDirectory}" classpathref="maven.test.classpath">
|
||||
+ <include name="scala/**/*.scala"/>
|
||||
+ </scalac>
|
||||
+ </tasks>
|
||||
+ </configuration>
|
||||
+ <goals>
|
||||
+ <goal>run</goal>
|
||||
+ </goals>
|
||||
+ </execution-->
|
||||
+ </executions>
|
||||
+ <dependencies>
|
||||
+ <dependency>
|
||||
+ <groupId>org.scala-lang</groupId>
|
||||
+ <artifactId>scala-compiler</artifactId>
|
||||
+ <version>2.10.2</version>
|
||||
+ </dependency>
|
||||
+ </dependencies>
|
||||
+ </plugin>
|
||||
+ <plugin>
|
||||
+ <groupId>org.apache.felix</groupId>
|
||||
+ <artifactId>maven-bundle-plugin</artifactId>
|
||||
+ <version>2.3.7</version>
|
||||
+ <extensions>true</extensions>
|
||||
+ <configuration>
|
||||
+ <instructions>
|
||||
+ <Bundle-SymbolicName>org.parboiled.scala</Bundle-SymbolicName>
|
||||
+ <Bundle-Name>org.parboiled.scala</Bundle-Name>
|
||||
+ <Bundle-Version>${project.version}</Bundle-Version>
|
||||
+ <Private-Package>org.parboiled.scala.*</Private-Package>
|
||||
+ </instructions>
|
||||
+ </configuration>
|
||||
+ <executions>
|
||||
+ <execution>
|
||||
+ <id>bundle-manifest</id>
|
||||
+ <phase>process-classes</phase>
|
||||
+ <goals>
|
||||
+ <goal>manifest</goal>
|
||||
+ </goals>
|
||||
+ </execution>
|
||||
+ </executions>
|
||||
+ </plugin>
|
||||
+ <plugin>
|
||||
+ <groupId>org.apache.maven.plugins</groupId>
|
||||
+ <artifactId>maven-jar-plugin</artifactId>
|
||||
+ <version>2.4</version>
|
||||
+ <configuration>
|
||||
+ <archive>
|
||||
+ <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
|
||||
+ </archive>
|
||||
+ </configuration>
|
||||
+ </plugin>
|
||||
+ </plugins>
|
||||
+ </build>
|
||||
+
|
||||
</project>
|
||||
\ Manca newline alla fine del file
|
@ -1,46 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<!-- This is a dummy POM added just to ease building in the RPM platforms: -->
|
||||
|
||||
<project
|
||||
xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.parboiled</groupId>
|
||||
<artifactId>parboiled-project</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
<version>@VERSION@</version>
|
||||
|
||||
<modules>
|
||||
<!-- These are not all the modules, only those that we can currently build: -->
|
||||
<module>parboiled-core</module>
|
||||
<module>parboiled-java</module>
|
||||
</modules>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<configuration>
|
||||
<source>1.5</source>
|
||||
<target>1.6</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<configuration>
|
||||
<includes>
|
||||
<include>**/*Tests.java</include>
|
||||
</includes>
|
||||
<excludes>
|
||||
<exclude>**/Abstract*.java</exclude>
|
||||
</excludes>
|
||||
<argLine>-Xmx512m</argLine>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
142
parboiled.spec
142
parboiled.spec
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package parboiled
|
||||
#
|
||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -25,31 +25,23 @@ License: Apache-2.0
|
||||
Group: Development/Libraries/Java
|
||||
URL: http://parboiled.org/
|
||||
Source0: https://github.com/sirthias/parboiled/archive/%{version}.tar.gz
|
||||
Source1: %{name}-%{version}-build.tar.xz
|
||||
# for build see https://github.com/sirthias/parboiled/wiki/Building-parboiled
|
||||
Source1: http://repo1.maven.org/maven2/org/parboiled/%{name}-core/%{version}/%{name}-core-%{version}.pom
|
||||
Source2: http://repo1.maven.org/maven2/org/parboiled/%{name}-java/%{version}/%{name}-java-%{version}.pom
|
||||
# customized aggregator pom
|
||||
Source3: %{name}-pom.xml
|
||||
Source2: http://repo1.maven.org/maven2/org/parboiled/%{name}-core/%{version}/%{name}-core-%{version}.pom
|
||||
Source3: http://repo1.maven.org/maven2/org/parboiled/%{name}-java/%{version}/%{name}-java-%{version}.pom
|
||||
Source4: http://repo1.maven.org/maven2/org/parboiled/%{name}-scala_%{scala_short_version}/%{version}/%{name}-scala_%{scala_short_version}-%{version}.pom
|
||||
Patch0: %{name}-1.1.6-scala-use-antrun-plugin.patch
|
||||
Patch1: parboiled-port-to-objectweb-asm-5.0.1.patch
|
||||
Patch0: parboiled-port-to-objectweb-asm-5.0.1.patch
|
||||
BuildRequires: ant
|
||||
BuildRequires: ant-scala
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: maven-local
|
||||
BuildRequires: mvn(org.apache.felix:maven-bundle-plugin)
|
||||
BuildRequires: mvn(org.apache.maven.plugins:maven-antrun-plugin)
|
||||
BuildRequires: mvn(org.ow2.asm:asm)
|
||||
BuildRequires: mvn(org.ow2.asm:asm-analysis)
|
||||
BuildRequires: mvn(org.ow2.asm:asm-tree)
|
||||
BuildRequires: mvn(org.ow2.asm:asm-util)
|
||||
BuildRequires: mvn(org.scala-lang:scala-compiler)
|
||||
BuildRequires: mvn(org.scala-lang:scala-library)
|
||||
BuildRequires: javapackages-local
|
||||
BuildRequires: objectweb-asm
|
||||
BuildConflicts: java-devel >= 9
|
||||
Requires: mvn(org.ow2.asm:asm)
|
||||
Requires: mvn(org.ow2.asm:asm-analysis)
|
||||
Requires: mvn(org.ow2.asm:asm-tree)
|
||||
Requires: mvn(org.ow2.asm:asm-util)
|
||||
BuildArch: noarch
|
||||
%if 0
|
||||
# test deps
|
||||
BuildRequires: mvn(org.scalatest:scalatest_2.9.3)
|
||||
BuildRequires: mvn(org.testng:testng)
|
||||
%endif
|
||||
|
||||
%description
|
||||
parboiled is a mixed Java/Scala library providing for lightweight and
|
||||
@ -61,103 +53,52 @@ a few advantages over the "traditional" way of building parser via CFGs.
|
||||
|
||||
%package scala
|
||||
Summary: Parboiled for Scala
|
||||
Group: Development/Libraries/Java
|
||||
Requires: mvn(org.parboiled:parboiled-core) = 1.1.6
|
||||
Requires: mvn(org.scala-lang:scala-library)
|
||||
|
||||
%description scala
|
||||
An internal Scala DSL for efficiently defining your parser rules.
|
||||
|
||||
%package javadoc
|
||||
Summary: Javadoc for %{name}
|
||||
Group: Documentation/HTML
|
||||
|
||||
%description javadoc
|
||||
This package contains javadoc for %{name}.
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%setup -q -a1
|
||||
|
||||
find . -name "*.class" -delete
|
||||
find . -name "*.jar" -delete
|
||||
|
||||
cp -p %{SOURCE1} %{name}-core/pom.xml
|
||||
cp -p %{SOURCE2} %{name}-java/pom.xml
|
||||
cp -p %{SOURCE4} %{name}-scala/pom.xml
|
||||
|
||||
for m in core java; do
|
||||
%pom_xpath_inject "pom:project" "
|
||||
<build>
|
||||
<plugins>
|
||||
|
||||
</plugins>
|
||||
</build>" %{name}-${m}
|
||||
|
||||
%pom_add_plugin org.apache.maven.plugins:maven-jar-plugin %{name}-${m} "
|
||||
<configuration>
|
||||
<archive>
|
||||
<manifestFile>\${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
|
||||
</archive>
|
||||
</configuration>"
|
||||
done
|
||||
|
||||
%pom_add_plugin org.apache.felix:maven-bundle-plugin %{name}-core "
|
||||
<extensions>true</extensions>
|
||||
<configuration>
|
||||
<instructions>
|
||||
<Bundle-SymbolicName>org.parboiled.core</Bundle-SymbolicName>
|
||||
<Bundle-Name>org.parboiled.core</Bundle-Name>
|
||||
<Bundle-Version>\${project.version}</Bundle-Version>
|
||||
<Private-Package>org.parboiled.core.*</Private-Package>
|
||||
</instructions>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>bundle-manifest</id>
|
||||
<phase>process-classes</phase>
|
||||
<goals>
|
||||
<goal>manifest</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>"
|
||||
|
||||
%pom_add_plugin org.apache.felix:maven-bundle-plugin %{name}-java "
|
||||
<extensions>true</extensions>
|
||||
<configuration>
|
||||
<instructions>
|
||||
<Bundle-SymbolicName>org.parboiled.java</Bundle-SymbolicName>
|
||||
<Bundle-Name>org.parboiled.java</Bundle-Name>
|
||||
<Bundle-Version>\${project.version}</Bundle-Version>
|
||||
<Fragment-Host>org.parboiled.core</Fragment-Host>
|
||||
<Private-Package>org.parboiled.java.*</Private-Package>
|
||||
</instructions>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>bundle-manifest</id>
|
||||
<phase>process-classes</phase>
|
||||
<goals>
|
||||
<goal>manifest</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>"
|
||||
|
||||
%patch0
|
||||
%patch1 -p1
|
||||
|
||||
cp -p %{SOURCE3} pom.xml
|
||||
sed -i "s|@VERSION@|%{version}|" pom.xml
|
||||
|
||||
%{mvn_file} :%{name}-core %{name}/core
|
||||
%{mvn_file} :%{name}-java %{name}/java
|
||||
%{mvn_package} :%{name}-project __noinstall
|
||||
%pom_xpath_inject "pom:modules" "<module>%{name}-scala</module>"
|
||||
%{mvn_file} :%{name}-scala_%{scala_short_version} %{name}/scala
|
||||
%{mvn_package} :%{name}-scala_%{scala_short_version} scala
|
||||
%patch0 -p1
|
||||
|
||||
%build
|
||||
|
||||
# test skipped unavailable dep org.scalatest scalatest_2.9.0 1.6.1
|
||||
%{mvn_build} -f -- -Dproject.build.sourceEncoding=UTF-8
|
||||
mkdir -p lib
|
||||
build-jar-repository -s lib objectweb-asm
|
||||
%{ant} -Dscala.libDir=%{_datadir}/scala/lib package javadoc
|
||||
|
||||
%install
|
||||
%mvn_install
|
||||
# jars
|
||||
install -dm 0755 %{buildroot}%{_javadir}/%{name}
|
||||
for i in core java scala; do
|
||||
install -pm 0644 %{name}-${i}/target/%{name}-${i}*%{version}.jar %{buildroot}%{_javadir}/%{name}/${i}.jar
|
||||
done
|
||||
# poms
|
||||
install -dm 0755 %{buildroot}%{_mavenpomdir}/%{name}
|
||||
install -pm 0644 %{SOURCE2} %{buildroot}%{_mavenpomdir}/%{name}/core.pom
|
||||
%add_maven_depmap %{name}/core.pom %{name}/core.jar
|
||||
install -pm 0644 %{SOURCE3} %{buildroot}%{_mavenpomdir}/%{name}/java.pom
|
||||
%add_maven_depmap %{name}/java.pom %{name}/java.jar
|
||||
install -pm 0644 %{SOURCE4} %{buildroot}%{_mavenpomdir}/%{name}/scala.pom
|
||||
%add_maven_depmap %{name}/scala.pom %{name}/scala.jar -f scala
|
||||
# javadoc
|
||||
for i in core java scala; do
|
||||
install -dm 0755 %{buildroot}%{_javadocdir}/%{name}/${i}
|
||||
cp -pr %{name}-${i}/target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}/${i}/
|
||||
done
|
||||
%fdupes -s %{buildroot}%{_javadocdir}
|
||||
|
||||
%files -f .mfiles
|
||||
@ -167,7 +108,8 @@ sed -i "s|@VERSION@|%{version}|" pom.xml
|
||||
%files scala -f .mfiles-scala
|
||||
%license LICENSE
|
||||
|
||||
%files javadoc -f .mfiles-javadoc
|
||||
%files javadoc
|
||||
%license LICENSE
|
||||
%{_javadocdir}/%{name}
|
||||
|
||||
%changelog
|
||||
|
Loading…
x
Reference in New Issue
Block a user