bug4811: added P2 repo project for AWS SDK

This commit is contained in:
Axel Uhl committed 2020-07-20 19:13:24 +02:00
1 parent 7188c98f88
commit d829ebdaa1
11 files changed
+243 -97

No files matched your search

+2
View File
@@ -0,0 +1,2 @@
/plugins/
/target/
+17
View File
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>com.amazon.aws.aws-java-api.updatesite</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.pde.UpdateSiteBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.UpdateSiteNature</nature>
</natures>
</projectDescription>
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<feature
id="com.amazon.aws.aws-java-api"
label="AWS API"
version="2.13.50"
provider-name="Amazon">
<plugin
id="com.amazon.aws.aws-java-api"
download-size="0"
install-size="0"
version="2.13.50"
unpack="false"/>
</feature>
+39
View File
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001 XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<!-- Do not set parent: this would also inherit the tycho target platform
configuration. By building this artifact, we create the local p2 repo that
can then be referenced by the race-analysis-p2-local.target definition. So
we can't recursively use the local repo as target platform for building the
local repo - and apart from that don't need it. Skipping the tycho-maven-plugin
and target-platform-configuration plugins via <skip> parameter in the build
config does not skip resolving the target definition defined in the parent
pom. Therefore, the parent was not set here - which means we have to define
$tycho-version again. -->
<groupId>com.amazon.aws</groupId>
<version>2.13.50</version>
<artifactId>com.amazon.aws.aws-java-api.updatesite</artifactId>
<build>
<plugins>
<plugin>
<groupId>org.eclipse.tycho.extras</groupId>
<artifactId>tycho-p2-extras-plugin</artifactId>
<version>1.0.0</version>
<configuration>
<sourceLocation>${basedir}</sourceLocation>
</configuration>
<executions>
<execution>
<id>generate-full-metadata</id>
<phase>compile</phase>
<goals>
<goal>publish-features-and-bundles</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
+7
View File
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<site>
<feature url="features/aws-sdk/com.amazon.aws.aws-java-api_2.13.50.jar" id="com.amazon.aws.aws-java-api" version="2.13.50">
<category name="aws-java-api"/>
</feature>
<category-def name="com.amazon.aws.aws-java-api" label="aws-java-api"/>
</site>
+44 -54
View File
@@ -1,57 +1,47 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry exported="true" kind="lib" path="lib/elasticloadbalancingv2-2.13.50.jar" sourcepath="lib/elasticloadbalancingv2-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/cloudwatch-2.13.50.jar" sourcepath="lib/cloudwatch-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/arns-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/auth-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/ec2-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/profiles-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/regions-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/route53-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/route53-2.13.50.jar" sourcepath="lib/route53-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/s3-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/sdk-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/utils-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/ec2-2.13.50.jar" sourcepath="lib/ec2-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/annotations-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/apache-client-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/arns-2.13.50.jar" sourcepath="lib/arns-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/auth-2.13.50.jar" sourcepath="lib/auth-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-core-2.13.50.jar" sourcepath="lib/aws-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-query-protocol-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-xml-protocol-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/commons-codec-1.11.jar"/>
<classpathentry exported="true" kind="lib" path="lib/commons-logging-1.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/eventstream-1.0.1.jar"/>
<classpathentry exported="true" kind="lib" path="lib/http-client-spi-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/httpclient-4.5.9.jar"/>
<classpathentry exported="true" kind="lib" path="lib/httpcore-4.4.11.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-annotations-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-core-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-databind-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-buffer-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-http-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-http2-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-common-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-handler-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-nio-client-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-reactive-streams-2.0.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-reactive-streams-http-2.0.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-resolver-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-native-epoll-4.1.46.Final-linux-x86_64.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-native-unix-common-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/profiles-2.13.50.jar" sourcepath="lib/profiles-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/protocol-core-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/reactive-streams-1.0.3.jar"/>
<classpathentry exported="true" kind="lib" path="lib/regions-2.13.50.jar" sourcepath="lib/regions-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/s3-2.13.50.jar" sourcepath="lib/s3-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/sdk-core-2.13.50.jar" sourcepath="lib/sdk-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/slf4j-api-1.7.28.jar"/>
<classpathentry exported="true" kind="lib" path="lib/utils-2.13.50.jar" sourcepath="lib/utils-2.13.50-sources.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="bin"/>
<classpathentry exported="true" kind="lib" path="lib/annotations-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/apache-client-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/arns-2.13.50.jar" sourcepath="lib/arns-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/auth-2.13.50.jar" sourcepath="lib/auth-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-core-2.13.50.jar" sourcepath="lib/aws-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-query-protocol-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/aws-xml-protocol-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/cloudwatch-2.13.50.jar" sourcepath="lib/cloudwatch-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/commons-codec-1.11.jar"/>
<classpathentry exported="true" kind="lib" path="lib/commons-logging-1.2.jar"/>
<classpathentry exported="true" kind="lib" path="lib/ec2-2.13.50.jar" sourcepath="lib/ec2-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/elasticloadbalancingv2-2.13.50.jar" sourcepath="lib/elasticloadbalancingv2-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/eventstream-1.0.1.jar"/>
<classpathentry exported="true" kind="lib" path="lib/httpclient-4.5.9.jar"/>
<classpathentry exported="true" kind="lib" path="lib/http-client-spi-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/httpcore-4.4.11.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-annotations-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-core-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/jackson-databind-2.10.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-buffer-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-http2-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-codec-http-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-common-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-handler-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-nio-client-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-reactive-streams-2.0.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-reactive-streams-http-2.0.4.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-resolver-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-native-epoll-4.1.46.Final-linux-x86_64.jar"/>
<classpathentry exported="true" kind="lib" path="lib/netty-transport-native-unix-common-4.1.46.Final.jar"/>
<classpathentry exported="true" kind="lib" path="lib/profiles-2.13.50.jar" sourcepath="lib/profiles-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/protocol-core-2.13.50.jar"/>
<classpathentry exported="true" kind="lib" path="lib/reactive-streams-1.0.3.jar"/>
<classpathentry exported="true" kind="lib" path="lib/regions-2.13.50.jar" sourcepath="lib/regions-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/route53-2.13.50.jar" sourcepath="lib/route53-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/s3-2.13.50.jar" sourcepath="lib/s3-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/sdk-core-2.13.50.jar" sourcepath="lib/sdk-core-2.13.50-sources.jar"/>
<classpathentry exported="true" kind="lib" path="lib/slf4j-api-1.7.28.jar"/>
<classpathentry exported="true" kind="lib" path="lib/utils-2.13.50.jar" sourcepath="lib/utils-2.13.50-sources.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="bin"/>
</classpath>
@@ -5,27 +5,29 @@ Bundle-SymbolicName: com.amazon.aws.aws-java-api
Bundle-Version: 2.13.50
Bundle-Vendor: Amazon
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Bundle-ClassPath: .,
lib/annotations-2.13.50.jar,
Bundle-ClassPath: lib/annotations-2.13.50.jar,
lib/apache-client-2.13.50.jar,
lib/arns-2.13.50.jar,
lib/auth-2.13.50.jar,
lib/aws-core-2.13.50.jar,
lib/aws-query-protocol-2.13.50.jar,
lib/aws-xml-protocol-2.13.50.jar,
lib/cloudwatch-2.13.50.jar,
lib/commons-codec-1.11.jar,
lib/commons-logging-1.2.jar,
lib/ec2-2.13.50.jar,
lib/elasticloadbalancingv2-2.13.50.jar,
lib/eventstream-1.0.1.jar,
lib/http-client-spi-2.13.50.jar,
lib/httpclient-4.5.9.jar,
lib/http-client-spi-2.13.50.jar,
lib/httpcore-4.4.11.jar,
lib/jackson-annotations-2.10.4.jar,
lib/jackson-core-2.10.4.jar,
lib/jackson-databind-2.10.4.jar,
lib/netty-buffer-4.1.46.Final.jar,
lib/netty-codec-4.1.46.Final.jar,
lib/netty-codec-http-4.1.46.Final.jar,
lib/netty-codec-http2-4.1.46.Final.jar,
lib/netty-codec-http-4.1.46.Final.jar,
lib/netty-common-4.1.46.Final.jar,
lib/netty-handler-4.1.46.Final.jar,
lib/netty-nio-client-2.13.50.jar,
@@ -39,24 +41,12 @@ Bundle-ClassPath: .,
lib/protocol-core-2.13.50.jar,
lib/reactive-streams-1.0.3.jar,
lib/regions-2.13.50.jar,
lib/route53-2.13.50.jar,
lib/s3-2.13.50.jar,
lib/sdk-core-2.13.50.jar,
lib/slf4j-api-1.7.28.jar,
lib/utils-2.13.50.jar,
lib/ec2-2.13.50.jar,
lib/arns-2.13.50-sources.jar,
lib/auth-2.13.50-sources.jar,
lib/aws-core-2.13.50-sources.jar,
lib/ec2-2.13.50-sources.jar,
lib/profiles-2.13.50-sources.jar,
lib/regions-2.13.50-sources.jar,
lib/route53-2.13.50-sources.jar,
lib/route53-2.13.50.jar,
lib/s3-2.13.50-sources.jar,
lib/sdk-core-2.13.50-sources.jar,
lib/utils-2.13.50-sources.jar,
lib/cloudwatch-2.13.50.jar,
lib/elasticloadbalancingv2-2.13.50.jar
.
Automatic-Module-Name: com.amazon.aws.aws-java-api
Export-Package: software.amazon.awssdk.annotations,
software.amazon.awssdk.arns,
@@ -1,54 +1,43 @@
bin.includes = META-INF/,\
.,\
lib/annotations-2.13.50.jar,\
lib/utils-2.13.50.jar,\
lib/sdk-core-2.13.50.jar,\
lib/s3-2.13.50.jar,\
lib/regions-2.13.50.jar,\
lib/apache-client-2.13.50.jar,\
lib/arns-2.13.50.jar,\
lib/auth-2.13.50.jar,\
lib/aws-core-2.13.50.jar,\
lib/aws-query-protocol-2.13.50.jar,\
lib/aws-xml-protocol-2.13.50.jar,\
lib/http-client-spi-2.13.50.jar,\
lib/netty-nio-client-2.13.50.jar,\
lib/profiles-2.13.50.jar,\
lib/protocol-core-2.13.50.jar,\
lib/cloudwatch-2.13.50.jar,\
lib/commons-codec-1.11.jar,\
lib/commons-logging-1.2.jar,\
lib/ec2-2.13.50.jar,\
lib/elasticloadbalancingv2-2.13.50.jar,\
lib/eventstream-1.0.1.jar,\
lib/httpclient-4.5.9.jar,\
lib/http-client-spi-2.13.50.jar,\
lib/httpcore-4.4.11.jar,\
lib/jackson-annotations-2.10.4.jar,\
lib/jackson-core-2.10.4.jar,\
lib/jackson-databind-2.10.4.jar,\
lib/netty-buffer-4.1.46.Final.jar,\
lib/netty-codec-4.1.46.Final.jar,\
lib/netty-codec-http-4.1.46.Final.jar,\
lib/netty-codec-http2-4.1.46.Final.jar,\
lib/netty-codec-http-4.1.46.Final.jar,\
lib/netty-common-4.1.46.Final.jar,\
lib/netty-handler-4.1.46.Final.jar,\
lib/netty-nio-client-2.13.50.jar,\
lib/netty-reactive-streams-2.0.4.jar,\
lib/netty-reactive-streams-http-2.0.4.jar,\
lib/netty-resolver-4.1.46.Final.jar,\
lib/netty-transport-4.1.46.Final.jar,\
lib/netty-transport-native-epoll-4.1.46.Final-linux-x86_64.jar,\
lib/netty-transport-native-unix-common-4.1.46.Final.jar,\
lib/profiles-2.13.50.jar,\
lib/protocol-core-2.13.50.jar,\
lib/reactive-streams-1.0.3.jar,\
lib/slf4j-api-1.7.28.jar,\
lib/ec2-2.13.50.jar,\
lib/arns-2.13.50-sources.jar,\
lib/auth-2.13.50-sources.jar,\
lib/aws-core-2.13.50-sources.jar,\
lib/ec2-2.13.50-sources.jar,\
lib/profiles-2.13.50-sources.jar,\
lib/regions-2.13.50-sources.jar,\
lib/route53-2.13.50-sources.jar,\
lib/regions-2.13.50.jar,\
lib/route53-2.13.50.jar,\
lib/s3-2.13.50-sources.jar,\
lib/sdk-core-2.13.50-sources.jar,\
lib/utils-2.13.50-sources.jar,\
lib/cloudwatch-2.13.50.jar,\
lib/elasticloadbalancingv2-2.13.50.jar
lib/s3-2.13.50.jar,\
lib/sdk-core-2.13.50.jar,\
lib/slf4j-api-1.7.28.jar,\
lib/utils-2.13.50.jar
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<launchConfiguration type="org.eclipse.jdt.launching.localJavaApplication">
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
<listEntry value="/com.sap.sailing.targetplatform.updater"/>
</listAttribute>
<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
<listEntry value="4"/>
</listAttribute>
<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.equinox.launcher.Main"/>
<stringAttribute key="org.eclipse.jdt.launching.MODULE_NAME" value="com.sap.sailing.targetplatform.updater"/>
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-consolelog -nosplash -verbose -application org.eclipse.equinox.p2.publisher.UpdateSitePublisher -metadataRepository &quot;file:/${project_loc:com.amazon.aws.aws-java-api.updatesite}/target/repository&quot; -artifactRepository &quot;file:/${project_loc:com.amazon.aws.aws-java-api.updatesite}/target/repository&quot; -source &quot;${project_loc:com.amazon.aws.aws-java-api.updatesite}&quot; -publishArtifacts -publishArtifactRepository -compress -noDefaultIUs"/>
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="com.sap.sailing.targetplatform.updater"/>
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-jar ${eclipse_home}plugins/org.eclipse.equinox.launcher_1.5.700.v20200207-2156.jar"/>
</launchConfiguration>
@@ -7,7 +7,8 @@
<listEntry value="4"/>
</listAttribute>
<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.eclipse.equinox.launcher.Main"/>
<stringAttribute key="org.eclipse.jdt.launching.MODULE_NAME" value="com.sap.sailing.targetplatform.updater"/>
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-consolelog -nosplash -verbose -application org.eclipse.equinox.p2.publisher.UpdateSitePublisher -metadataRepository &quot;file:/${project_loc:com.sap.sailing.targetplatform.base}/target/repository&quot; -artifactRepository &quot;file:/${project_loc:com.sap.sailing.targetplatform.base}/target/repository&quot; -source &quot;${project_loc:com.sap.sailing.targetplatform.base}&quot; -publishArtifacts -publishArtifactRepository -compress -noDefaultIUs"/>
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="com.sap.sailing.targetplatform.updater"/>
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-jar ${eclipse_home}plugins/org.eclipse.equinox.launcher_1.3.0.v20140415-2008.jar"/>
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-jar ${eclipse_home}plugins/org.eclipse.equinox.launcher_1.5.700.v20200207-2156.jar"/>
</launchConfiguration>
@@ -0,0 +1,82 @@
#!/bin/bash
# Uses a gradle build in java/com.amazon.aws.aws-java-api to obtain the JARs for the AWS Java API (SDK)
# into the lib/ folder there, then generates a corresponding .classpath, META-INF/MANIFEST.MF, and build.properties file.
# Then, the java/com.amazon.aws.aws-java-api.updatesite/features/aws-sdk/feature.xml is adjusted to reflect the current version.
# The update site is then built locally into java/com.amazon.aws.aws-java-api.updatesite/target/repository which can then
# be tested with the local target platform definition. If everything works fine, the uploadAwsApiRepositoryToServer.sh script
# can be used to update the repository contents at p2.sapsailing.com with the updated local target platform repository contents.
LIB=lib
CLASSPATH_FILE=".classpath"
MANIFEST_FILE="MANIFEST.MF"
BUILD_PROPERTIES_FILE="build.properties"
WORKSPACE=`realpath \`dirname $0\`/../../..`
echo WORKSPACE: $WORKSPACE
UPDATE_SITE_PROJECT=${WORKSPACE}/java/com.amazon.aws.aws-java-api.updatesite
WRAPPER_BUNDLE="${WORKSPACE}/java/com.amazon.aws.aws-java-api"
cd ${WRAPPER_BUNDLE}
echo "Downloading libraries..."
# TODO re-enable
#${WORKSPACE}/gradlew downloadLibs
cd ${LIB}
VERSION=`ls -1 aws-core-*.jar | grep -v -- -sources | sed -e 's/aws-core-\([.0-9]*\)\.jar/\1/'`
echo VERSION=${VERSION}
LIBS=`ls -1 | grep -v -- -sources\.jar`
echo "Generating the .classpath file..."
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>
<classpath>" >${WRAPPER_BUNDLE}/${CLASSPATH_FILE}
for l in ${LIBS}; do
SOURCES_JAR=`basename $l .jar`-sources.jar
if [ -f ${SOURCES_JAR} ]; then
SOURCEPATH=" sourcepath=\"${LIB}/${SOURCES_JAR}\""
else
SOURCEPATH=""
fi
echo " <classpathentry exported=\"true\" kind=\"lib\" path=\"${LIB}/${l}\"${SOURCEPATH}/>" >>${WRAPPER_BUNDLE}/${CLASSPATH_FILE}
done
echo " <classpathentry kind=\"con\" path=\"org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8\"/>
<classpathentry kind=\"con\" path=\"org.eclipse.pde.core.requiredPlugins\"/>
<classpathentry kind=\"output\" path=\"bin\"/>
</classpath>" >>${WRAPPER_BUNDLE}/${CLASSPATH_FILE}
echo "Patching version ${VERSION} into pom.xml..."
# exclude SNAPSHOT version used for the parent pom; only match the explicit SDK version
sed -i -e 's/<version>\([0-9.]*\)<\/version>/<version>'${VERSION}'<\/version>/' ${WRAPPER_BUNDLE}/pom.xml
echo "Generating the META-INF/MANIFEST.MF file..."
echo -n "Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: aws-java-api
Bundle-SymbolicName: com.amazon.aws.aws-java-api
Bundle-Version: ${VERSION}
Bundle-Vendor: Amazon
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Bundle-ClassPath: " >${WRAPPER_BUNDLE}/META-INF/${MANIFEST_FILE}
for l in ${LIBS}; do
echo -n "lib/${l},
" >>${WRAPPER_BUNDLE}/META-INF/${MANIFEST_FILE}
done
echo " ...determining exported packages from libs to generate Export-Package in manifest..."
echo -n ".
Automatic-Module-Name: com.amazon.aws.aws-java-api
Export-Package:" >>${WRAPPER_BUNDLE}/META-INF/${MANIFEST_FILE}
PACKAGES=$(for l in ${LIBS}; do
jar tvf ${l} | grep "\.class\>" | sed -e 's/^.* \([^ ]*\)$/\1/' -e 's/\/[^/]*\.class\>//' | grep "^software/amazon"
done | sort -u | tr / . )
for p in `echo "${PACKAGES}" | while read i; do echo $i | sed -e 's/^\([-a-zA-Z0-9_.]*\)\>.*$/\1/'; done | head --lines=-1`; do
echo " ${p}," >>${WRAPPER_BUNDLE}/META-INF/${MANIFEST_FILE}
done
for p in `echo "${PACKAGES}" | while read i; do echo $i | sed -e 's/^\([-a-zA-Z0-9_.]*\)\>.*$/\1/'; done | tail --lines=1`; do
echo " ${p}" >>${WRAPPER_BUNDLE}/META-INF/${MANIFEST_FILE}
done
echo "Generating build.properties..."
echo -n "bin.includes = META-INF/,\\
." >${WRAPPER_BUNDLE}/${BUILD_PROPERTIES_FILE}
for l in ${LIBS}; do
echo -n ",\\
lib/${l}" >>${WRAPPER_BUNDLE}/${BUILD_PROPERTIES_FILE}
done
echo >>${WRAPPER_BUNDLE}/${BUILD_PROPERTIES_FILE}
echo "Building the wrapper bundle..."
cd ..
mvn clean install
mv bin/com.amazon.aws.aws-java-api-${VERSION}.jar ${UPDATE_SITE_PROJECT}/plugins/aws-sdk
cd ${UPDATE_SITE_PROJECT}
mvn clean install