commit
d207172c0b
BIN
1.1-rc5.tar.gz
Normal file
BIN
1.1-rc5.tar.gz
Normal file
Binary file not shown.
26
jcsp-create-tarball.sh
Normal file
26
jcsp-create-tarball.sh
Normal file
@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ $# -ne 1 ]; then
|
||||
echo "Usage: ./create-sources VERSION"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VERSION=${1}
|
||||
NAME="jcsp"
|
||||
|
||||
wget https://github.com/codehaus/${NAME}/archive/${VERSION}.tar.gz
|
||||
tar -xf ${VERSION}.tar.gz
|
||||
rm ${VERSION}.tar.gz
|
||||
find ./${NAME}-${VERSION} -name "*.jar" -delete
|
||||
find ./${NAME}-${VERSION} -name "*.class" -delete
|
||||
# Remove unused files
|
||||
rm -Rf ./${NAME}-${VERSION}/*gradle*
|
||||
rm -Rf ./${NAME}-${VERSION}/wrapper
|
||||
rm -Rf ./${NAME}-${VERSION}/.gitignore
|
||||
rm -Rf ./${NAME}-${VERSION}/src/jcsp-demos
|
||||
rm -Rf ./${NAME}-${VERSION}/src/org/jcsp/win32/Installing\ NT\ Services.txt
|
||||
rm -Rf ./${NAME}-${VERSION}/src/org/jcsp/win32/*.c*
|
||||
rm -Rf ./${NAME}-${VERSION}/src/org/jcsp/win32/*.h*
|
||||
rm -Rf ./${NAME}-${VERSION}/JCSP\ Networking.pdf
|
||||
|
||||
tar cJf ${NAME}-${VERSION}-clean.tar.xz ./${NAME}-${VERSION}
|
||||
79
jcsp.spec
Normal file
79
jcsp.spec
Normal file
@ -0,0 +1,79 @@
|
||||
Name: jcsp
|
||||
Version: 1.1
|
||||
Release: 0.13
|
||||
Summary: Communicating Sequential Processes for Java (JCSP)
|
||||
License: LGPLv2+
|
||||
URL: https://github.com/codehaus/jcsp
|
||||
Source0: https://github.com/codehaus/jcsp/archive/1.1-rc5.tar.gz
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: maven-local junit maven-plugin-bundle osgi-core
|
||||
|
||||
Provides: %{name}-javadoc = %{name}-%{release}
|
||||
Obsoletes: %{name}-javadoc < %{name}-%{release}
|
||||
|
||||
%description
|
||||
JCSP is an implementation of Communicating Sequential Processes
|
||||
(CSP) for the Java programming language.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version}-rc5 -p1
|
||||
find ./ -name "*.jar" -delete
|
||||
find ./ -name "*.class" -delete
|
||||
rm -Rf ./*gradle* ./wrapper ./.gitignore ./src/jcsp-demos
|
||||
rm -Rf ./src/org/jcsp/win32/Installing\ NT\ Services.txt
|
||||
rm -Rf ./src/org/jcsp/win32/*.c* ./src/org/jcsp/win32/*.h*
|
||||
rm -Rf ./JCSP\ Networking.pdf
|
||||
for plugin in cobertura-maven-plugin findbugs-maven-plugin jdepend-maven-plugin \
|
||||
rat-maven-plugin taglist-maven-plugin ; do
|
||||
%pom_remove_plugin :$plugin
|
||||
done
|
||||
|
||||
%pom_change_dep :org.osgi.core org.osgi:osgi.core
|
||||
|
||||
%pom_xpath_remove "pom:project/pom:build/pom:extensions"
|
||||
|
||||
%pom_xpath_inject "pom:project/pom:build" "
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src</directory>
|
||||
<excludes>
|
||||
<exclude>**/*.java</exclude>
|
||||
<exclude>**/doc-files/**</exclude>
|
||||
<exclude>**/win32/*Services.txt</exclude>
|
||||
<exclude>**/package.html</exclude>
|
||||
</excludes>
|
||||
</resource>
|
||||
</resources>"
|
||||
|
||||
%pom_xpath_remove "pom:project/pom:reporting/pom:plugins/pom:plugin[pom:artifactId='maven-javadoc-plugin']/pom:configuration/pom:excludePackageNames"
|
||||
%pom_xpath_remove "pom:project/pom:build/pom:plugins/pom:plugin[pom:artifactId='maven-bundle-plugin']/pom:configuration/pom:instructions/pom:Export-Package"
|
||||
%pom_xpath_inject "pom:project/pom:build/pom:plugins/pom:plugin[pom:artifactId='maven-bundle-plugin']/pom:configuration/pom:instructions" '
|
||||
<Export-Package>org.jcsp.*;version="${project.version}"</Export-Package>'
|
||||
|
||||
sed -i 's|${name}|${project.name}|' pom.xml
|
||||
|
||||
pushd src/org/jcsp
|
||||
rm -r win32 net/remote/SpawnerServiceNT.java net/tcpip/TCPIPCNSServerNT.java
|
||||
popd
|
||||
|
||||
%mvn_file : jcsp
|
||||
|
||||
%build
|
||||
%mvn_build -- -Dproject.build.sourceEncoding=UTF-8
|
||||
|
||||
%install
|
||||
%mvn_install
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc README.txt
|
||||
%license LICENCE.txt
|
||||
%{_datadir}/java/*
|
||||
%{_datadir}/javadoc/*
|
||||
%{_datadir}/maven-poms/*
|
||||
%{_datadir}/maven-metadata/*
|
||||
|
||||
%changelog
|
||||
* Fri Feb 14 2020 gulining<gulining1@huawei.com> - 1.1-0.13
|
||||
- Package init
|
||||
Loading…
x
Reference in New Issue
Block a user