SHA256
1
0
forked from pool/parboiled
Fridrich Strba 2019-11-27 06:38:31 +00:00 committed by Git OBS Bridge
parent a15fb9ce99
commit 069ce6fbfa
5 changed files with 123 additions and 23 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:abf6c8f76c4bad243e1a4cba7339cb605d732b08113e225dbcedbb0684e921c4 oid sha256:c83549bddd26b2e6a7dce072e3745b609649776dfcf92d636e35f39d50229b8a
size 2692 size 2804

16
parboiled-scala.changes Normal file
View File

@ -0,0 +1,16 @@
-------------------------------------------------------------------
Wed Nov 27 06:37:29 UTC 2019 - Fridrich Strba <fstrba@suse.com>
- Split the scala subpackage from the main parboiled package in
order to split build dependencies
-------------------------------------------------------------------
Tue Apr 9 08:17:03 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
- Ensure neutrality of description.
-------------------------------------------------------------------
Wed Apr 3 09:09:39 UTC 2019 - Fridrich Strba <fstrba@suse.com>
- Initial packaging of parboiled 1.1.6
- Generate and customize ant build files

95
parboiled-scala.spec Normal file
View File

@ -0,0 +1,95 @@
#
# spec file for package parboiled-scala
#
# Copyright (c) 2019 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%global scala_short_version 2.10
%global base_name parboiled
Name: %{base_name}-scala
Version: 1.1.6
Release: 0
Summary: Parboiled for Scala
License: Apache-2.0
Group: Development/Libraries/Java
URL: http://parboiled.org/
Source0: https://github.com/sirthias/parboiled/archive/%{version}.tar.gz
Source1: %{base_name}-%{version}-build.tar.xz
# for build see https://github.com/sirthias/parboiled/wiki/Building-parboiled
Source2: http://repo1.maven.org/maven2/org/parboiled/%{base_name}-core/%{version}/%{base_name}-core-%{version}.pom
Source3: http://repo1.maven.org/maven2/org/parboiled/%{base_name}-java/%{version}/%{base_name}-java-%{version}.pom
Source4: http://repo1.maven.org/maven2/org/parboiled/%{base_name}-scala_%{scala_short_version}/%{version}/%{base_name}-scala_%{scala_short_version}-%{version}.pom
Patch0: parboiled-port-to-objectweb-asm-5.0.1.patch
BuildRequires: ant
BuildRequires: ant-scala
BuildRequires: fdupes
BuildRequires: javapackages-local
BuildRequires: parboiled
BuildConflicts: java-devel >= 9
Requires: mvn(org.parboiled:parboiled-core) = %{version}
Requires: mvn(org.scala-lang:scala-library)
BuildArch: noarch
%description
An internal Scala DSL for efficiently defining your parser rules.
parboiled is a mixed Java/Scala library providing parsing of
arbitrary input text based on Parsing expression grammars (PEGs).
PEGs are an alternative to context free grammars (CFGs) for formally
specifying syntax, they make a replacement for regular expressions
and generally have some advantages over the "traditional" way of
building parser via CFGs.
%package javadoc
Summary: Javadoc for %{name}
Group: Documentation/HTML
%description javadoc
This package contains javadoc for %{name}.
%prep
%setup -q -n %{base_name}-%{version} -a1
find . -name "*.class" -delete
find . -name "*.jar" -delete
%patch0 -p1
%build
mkdir -p lib
build-jar-repository -s lib %{base_name}
%{ant} -Dscala.libDir=%{_datadir}/scala/lib -f build-scala.xml package javadoc
%install
# jars
install -dm 0755 %{buildroot}%{_javadir}/%{base_name}
install -pm 0644 %{base_name}-scala/target/%{base_name}-scala*%{version}.jar %{buildroot}%{_javadir}/%{base_name}/scala.jar
# poms
install -dm 0755 %{buildroot}%{_mavenpomdir}/%{base_name}
install -pm 0644 %{SOURCE4} %{buildroot}%{_mavenpomdir}/%{base_name}/scala.pom
%add_maven_depmap %{base_name}/scala.pom %{base_name}/scala.jar
# javadoc
install -dm 0755 %{buildroot}%{_javadocdir}/%{base_name}/scala
cp -pr %{base_name}-scala/target/site/apidocs/* %{buildroot}%{_javadocdir}/%{base_name}/scala/
%fdupes -s %{buildroot}%{_javadocdir}
%files -f .mfiles
%license LICENSE
%files javadoc
%license LICENSE
%{_javadocdir}/%{base_name}
%changelog

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Nov 27 06:37:29 UTC 2019 - Fridrich Strba <fstrba@suse.com>
- Split the scala subpackage from the main parboiled package in
order to split build dependencies
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Apr 9 08:17:03 UTC 2019 - Jan Engelhardt <jengelh@inai.de> Tue Apr 9 08:17:03 UTC 2019 - Jan Engelhardt <jengelh@inai.de>

View File

@ -1,7 +1,7 @@
# #
# spec file for package parboiled # spec file for package parboiled
# #
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2019 SUSE LLC
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@ -29,14 +29,11 @@ Source1: %{name}-%{version}-build.tar.xz
# for build see https://github.com/sirthias/parboiled/wiki/Building-parboiled # for build see https://github.com/sirthias/parboiled/wiki/Building-parboiled
Source2: http://repo1.maven.org/maven2/org/parboiled/%{name}-core/%{version}/%{name}-core-%{version}.pom 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 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: parboiled-port-to-objectweb-asm-5.0.1.patch Patch0: parboiled-port-to-objectweb-asm-5.0.1.patch
BuildRequires: ant BuildRequires: ant
BuildRequires: ant-scala
BuildRequires: fdupes BuildRequires: fdupes
BuildRequires: javapackages-local BuildRequires: javapackages-local
BuildRequires: objectweb-asm BuildRequires: objectweb-asm
BuildConflicts: java-devel >= 9
Requires: mvn(org.ow2.asm:asm) Requires: mvn(org.ow2.asm:asm)
Requires: mvn(org.ow2.asm:asm-analysis) Requires: mvn(org.ow2.asm:asm-analysis)
Requires: mvn(org.ow2.asm:asm-tree) Requires: mvn(org.ow2.asm:asm-tree)
@ -51,15 +48,6 @@ specifying syntax, they make a replacement for regular expressions
and generally have some advantages over the "traditional" way of and generally have some advantages over the "traditional" way of
building parser via CFGs. 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 %package javadoc
Summary: Javadoc for %{name} Summary: Javadoc for %{name}
Group: Documentation/HTML Group: Documentation/HTML
@ -78,12 +66,12 @@ find . -name "*.jar" -delete
%build %build
mkdir -p lib mkdir -p lib
build-jar-repository -s lib objectweb-asm build-jar-repository -s lib objectweb-asm
%{ant} -Dscala.libDir=%{_datadir}/scala/lib package javadoc %{ant} package javadoc
%install %install
# jars # jars
install -dm 0755 %{buildroot}%{_javadir}/%{name} install -dm 0755 %{buildroot}%{_javadir}/%{name}
for i in core java scala; do for i in core java; do
install -pm 0644 %{name}-${i}/target/%{name}-${i}*%{version}.jar %{buildroot}%{_javadir}/%{name}/${i}.jar install -pm 0644 %{name}-${i}/target/%{name}-${i}*%{version}.jar %{buildroot}%{_javadir}/%{name}/${i}.jar
done done
# poms # poms
@ -92,10 +80,8 @@ install -pm 0644 %{SOURCE2} %{buildroot}%{_mavenpomdir}/%{name}/core.pom
%add_maven_depmap %{name}/core.pom %{name}/core.jar %add_maven_depmap %{name}/core.pom %{name}/core.jar
install -pm 0644 %{SOURCE3} %{buildroot}%{_mavenpomdir}/%{name}/java.pom install -pm 0644 %{SOURCE3} %{buildroot}%{_mavenpomdir}/%{name}/java.pom
%add_maven_depmap %{name}/java.pom %{name}/java.jar %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 # javadoc
for i in core java scala; do for i in core java; do
install -dm 0755 %{buildroot}%{_javadocdir}/%{name}/${i} install -dm 0755 %{buildroot}%{_javadocdir}/%{name}/${i}
cp -pr %{name}-${i}/target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}/${i}/ cp -pr %{name}-${i}/target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}/${i}/
done done
@ -105,9 +91,6 @@ done
%doc CHANGELOG README.markdown %doc CHANGELOG README.markdown
%license LICENSE %license LICENSE
%files scala -f .mfiles-scala
%license LICENSE
%files javadoc %files javadoc
%license LICENSE %license LICENSE
%{_javadocdir}/%{name} %{_javadocdir}/%{name}