Browse Source

Maven to use protobuf-javanano 3.0.0-alpha-7 from Maven Central

pull/1286/head
Keghani Kouzoujian 9 years ago
committed by GitHub
parent
commit
c685bb4fcf
12 changed files with 38 additions and 101 deletions
  1. BIN
      java/lib/com/google/protobuf/protobuf-java/2.6.1/protobuf-java-2.6.1.jar
  2. +0
    -9
      java/lib/com/google/protobuf/protobuf-java/2.6.1/protobuf-java-2.6.1.pom
  3. +0
    -12
      java/lib/com/google/protobuf/protobuf-java/maven-metadata-local.xml
  4. BIN
      java/lib/protobuf-javanano-3.0.0-alpha-7.jar
  5. +20
    -0
      java/lib/protobuf-javanano-readme.md
  6. +4
    -31
      java/libphonenumber/pom.xml
  7. +2
    -0
      java/pending_code_changes.txt
  8. +4
    -9
      tools/java/common/pom.xml
  9. +4
    -31
      tools/java/cpp-build/pom.xml
  10. BIN
      tools/java/cpp-build/target/cpp-build-1.0-SNAPSHOT-jar-with-dependencies.jar
  11. +4
    -9
      tools/java/java-build/pom.xml
  12. BIN
      tools/java/java-build/target/java-build-1.0-SNAPSHOT-jar-with-dependencies.jar

BIN
java/lib/com/google/protobuf/protobuf-java/2.6.1/protobuf-java-2.6.1.jar View File


+ 0
- 9
java/lib/com/google/protobuf/protobuf-java/2.6.1/protobuf-java-2.6.1.pom View File

@ -1,9 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>2.6.1</version>
<description>POM was created from install:install-file</description>
</project>

+ 0
- 12
java/lib/com/google/protobuf/protobuf-java/maven-metadata-local.xml View File

@ -1,12 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<metadata>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<versioning>
<release>2.6.1</release>
<versions>
<version>2.6.1</version>
</versions>
<lastUpdated>20151102180249</lastUpdated>
</versioning>
</metadata>

BIN
java/lib/protobuf-javanano-3.0.0-alpha-7.jar View File


+ 20
- 0
java/lib/protobuf-javanano-readme.md View File

@ -0,0 +1,20 @@
Steps to update the protobuf library version:
- Start by finding a protobuf library version released to Maven Central that has functionality you
need, e.g. nano. See http://mvnrepository.com/artifact/com.google.protobuf.
- Update the protobuf library dependency's `groupId`, `artifactId`, and `version` to match this
artifact in all the `pom.xml` files. You can find the files by searching for
`<groupId>com.google.protobuf` in the GitHub repository.
- Download the `.jar` from the Maven Repository,
e.g. from http://repo1.maven.org/maven2/com/google/protobuf/nano/protobuf-javanano/3.0.0-alpha-7/,
and copy to `java/lib/`, replacing the previous version's `.jar`.
- See https://github.com/google/protobuf/releases for the release containing the chosen version, and
download the `protoc` binary for your machine's architecture from the same release and use this to
re-generate `java/libphonenumber/src/com/google/i18n/phonenumbers/nano/Phonemetadata.java` and
check in any changes to this file. The command from the root directory is:
```
protoc --javanano_out=com.google.i18n.phonenumbers.nano:java/libphonenumber/src \
resources/phonemetadata.proto \
--proto_path=resources
```

+ 4
- 31
java/libphonenumber/pom.xml View File

@ -29,28 +29,6 @@
</testResource>
</testResources>
<plugins>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<version>2.4.2</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<relocations>
<relocation>
<pattern>com.google.protobuf</pattern>
<shadedPattern>
com.google.i18n.phonenumbers.repackaged.com.google.protobuf
</shadedPattern>
</relocation>
</relocations>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
@ -74,17 +52,12 @@
</plugins>
</build>
<repositories>
<repository>
<id>protobuf-java-lib</id>
<url>file://${project.basedir}/../lib</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>2.6.1</version>
<groupId>com.google.protobuf.nano</groupId>
<artifactId>protobuf-javanano</artifactId>
<!-- If updating the version, see instructions in java/lib/protobuf-javanano-readme.md. -->
<version>3.0.0-alpha-7</version>
</dependency>
</dependencies>


+ 2
- 0
java/pending_code_changes.txt View File

@ -1,3 +1,5 @@
- Deleted unsupported SingleFilePhoneNumberMetadataProto.
Code changes:
- Refactored metadata loading and closed all streams after loading.
Build changes:
- Use protobuf-javanano 3.0.0-alpha-7 from Maven Central.

+ 4
- 9
tools/java/common/pom.xml View File

@ -51,12 +51,6 @@
</plugins>
</build>
<repositories>
<repository>
<id>protobuf-java-lib</id>
<url>file://${project.basedir}/../../../java/lib</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>junit</groupId>
@ -65,9 +59,10 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>2.6.1</version>
<groupId>com.google.protobuf.nano</groupId>
<artifactId>protobuf-javanano</artifactId>
<!-- If updating the version, see instructions in java/lib/protobuf-javanano-readme.md. -->
<version>3.0.0-alpha-7</version>
</dependency>
</dependencies>


+ 4
- 31
tools/java/cpp-build/pom.xml View File

@ -54,28 +54,6 @@
</execution>
</executions>
</plugin>
<!-- Invoke Protocol Buffers compiler to generate Phonemetadata.java. -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.4.0</version>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
<configuration>
<executable>protoc</executable>
<arguments>
<argument>--javanano_out=java_package=phonemetadata.proto|com.google.i18n.phonenumbers.nano:../../../java/libphonenumber/src</argument>
<argument>../../../resources/phonemetadata.proto</argument>
<argument>--proto_path=../../../resources</argument>
</arguments>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
@ -118,12 +96,6 @@
</plugins>
</build>
<repositories>
<repository>
<id>protobuf-java-lib</id>
<url>file://${project.basedir}/../../../java/lib</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>junit</groupId>
@ -132,9 +104,10 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>2.6.1</version>
<groupId>com.google.protobuf.nano</groupId>
<artifactId>protobuf-javanano</artifactId>
<!-- If updating the version, see instructions in java/lib/protobuf-javanano-readme.md. -->
<version>3.0.0-alpha-7</version>
</dependency>
</dependencies>


BIN
tools/java/cpp-build/target/cpp-build-1.0-SNAPSHOT-jar-with-dependencies.jar View File


+ 4
- 9
tools/java/java-build/pom.xml View File

@ -103,12 +103,6 @@
</plugins>
</build>
<repositories>
<repository>
<id>protobuf-java-lib</id>
<url>file://${project.basedir}/../../../java/lib</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>junit</groupId>
@ -117,9 +111,10 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>2.6.1</version>
<groupId>com.google.protobuf.nano</groupId>
<artifactId>protobuf-javanano</artifactId>
<!-- If updating the version, see instructions in java/lib/protobuf-javanano-readme.md. -->
<version>3.0.0-alpha-7</version>
</dependency>
</dependencies>


BIN
tools/java/java-build/target/java-build-1.0-SNAPSHOT-jar-with-dependencies.jar View File


Loading…
Cancel
Save