Krzysztof Daniel 594dc7
#!/bin/bash
Krzysztof Daniel 5dda4f
set -e
Krzysztof Daniel 5eaee8
AGGREGATOR_PATH=git://git.eclipse.org/gitroot/platform/eclipse.platform.releng.aggregator.git
ceeed8
TAG=R4_5
Krzysztof Daniel 054847
Krzysztof Daniel 5eaee8
rm -rf R4_platform-aggregator-$TAG
Krzysztof Daniel 781979
rm -rf R4_platform-aggregator-$TAG.tar.xz
Krzysztof Daniel 594dc7
Mat Booth f0d416
# adding --depth 1 here may result in a quicker clone, but did not work for me
Mat Booth f0d416
git clone --branch $TAG  $AGGREGATOR_PATH R4_platform-aggregator-$TAG
Mat Booth f0d416
Krzysztof Daniel 594dc7
Krzysztof Daniel 5eaee8
pushd R4_platform-aggregator-$TAG
Krzysztof Daniel 5eaee8
Krzysztof Daniel 5eaee8
git submodule init
Krzysztof Daniel 781979
git submodule update
Krzysztof Daniel 5eaee8
a69dbc
rm -rf bootstrap streams scripts
Krzysztof Daniel 5eaee8
54a04f
# Comment this line to get a shallow clone.
54a04f
find . -type d -name ".git" | xargs rm -rf
Krzysztof Daniel 5eaee8
62588a
# Delete pre-built binary artifacts except some test data that cannot be generated
62588a
find . ! -path "*/JCL/*" \
62588a
   -type f -name *.jar -delete
54a04f
find . -type f -name *.class -delete
54a04f
find . -type f -name *.so -delete
54a04f
find . -type f -name *.dll -delete
54a04f
find . -type f -name *.jnilib -delete
62588a
find . -type f -name *.exe -delete
365159
# Remove pre-compiled native launchers
365159
rm -rf rt.equinox.binaries/org.eclipse.equinox.executable/{bin,contributed}/
Krzysztof Daniel 5eaee8
Krzysztof Daniel 054847
popd 
Krzysztof Daniel 5eaee8
Mat Booth f0d416
tar cJf R4_platform-aggregator-$TAG.tar.xz R4_platform-aggregator-$TAG