Home | History | Annotate | Download | only in java
      1 <?xml version="1.0" encoding="UTF-8"?>
      2 <project xmlns="http://maven.apache.org/POM/4.0.0"
      3   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      4   xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
      5   <modelVersion>4.0.0</modelVersion>
      6   <parent>
      7     <groupId>com.google</groupId>
      8     <artifactId>google</artifactId>
      9     <version>1</version>
     10   </parent>
     11   <groupId>com.google.protobuf</groupId>
     12   <artifactId>protobuf-java</artifactId>
     13   <version>2.6.1</version>
     14   <packaging>bundle</packaging>
     15   <name>Protocol Buffer Java API</name>
     16   <description>
     17     Protocol Buffers are a way of encoding structured data in an efficient yet
     18     extensible format.
     19   </description>
     20   <inceptionYear>2008</inceptionYear>
     21   <url>https://developers.google.com/protocol-buffers/</url>
     22   <licenses>
     23     <license>
     24       <name>New BSD license</name>
     25       <url>http://www.opensource.org/licenses/bsd-license.php</url>
     26       <distribution>repo</distribution>
     27     </license>
     28   </licenses>
     29   <scm>
     30     <url>https://github.com/google/protobuf</url>
     31     <connection>
     32       scm:git:https://github.com/google/protobuf.git
     33     </connection>
     34   </scm>
     35   <dependencies>
     36     <dependency>
     37       <groupId>junit</groupId>
     38       <artifactId>junit</artifactId>
     39       <version>4.4</version>
     40       <scope>test</scope>
     41     </dependency>
     42     <dependency>
     43       <groupId>org.easymock</groupId>
     44       <artifactId>easymock</artifactId>
     45       <version>2.2</version>
     46       <scope>test</scope>
     47     </dependency>
     48     <dependency>
     49       <groupId>org.easymock</groupId>
     50       <artifactId>easymockclassextension</artifactId>
     51       <version>2.2.1</version>
     52       <scope>test</scope>
     53     </dependency>
     54   </dependencies>
     55   <build>
     56     <plugins>
     57       <plugin>
     58         <artifactId>maven-compiler-plugin</artifactId>
     59         <configuration>
     60           <source>1.5</source>
     61           <target>1.5</target>
     62         </configuration>
     63       </plugin>
     64       <plugin>
     65         <artifactId>maven-surefire-plugin</artifactId>
     66         <configuration>
     67           <includes>
     68             <include>**/*Test.java</include>
     69           </includes>
     70         </configuration>
     71       </plugin>
     72       <plugin>
     73         <artifactId>maven-antrun-plugin</artifactId>
     74         <executions>
     75           <execution>
     76             <id>generate-sources</id>
     77             <phase>generate-sources</phase>
     78             <configuration>
     79               <tasks>
     80                 <mkdir dir="target/generated-sources" />
     81                 <exec executable="../src/protoc">
     82                   <arg value="--java_out=target/generated-sources" />
     83                   <arg value="--proto_path=../src" />
     84                   <arg value="../src/google/protobuf/descriptor.proto" />
     85                 </exec>
     86               </tasks>
     87               <sourceRoot>target/generated-sources</sourceRoot>
     88             </configuration>
     89             <goals>
     90               <goal>run</goal>
     91             </goals>
     92           </execution>
     93           <execution>
     94             <id>generate-test-sources</id>
     95             <phase>generate-test-sources</phase>
     96             <configuration>
     97               <tasks>
     98                 <mkdir dir="target/generated-test-sources" />
     99                 <exec executable="../src/protoc">
    100                   <arg value="--java_out=target/generated-test-sources" />
    101                   <arg value="--proto_path=../src" />
    102                   <arg value="--proto_path=src/test/java" />
    103                   <arg value="../src/google/protobuf/unittest.proto" />
    104                   <arg value="../src/google/protobuf/unittest_import.proto" />
    105                   <arg value="../src/google/protobuf/unittest_import_public.proto" />
    106                   <arg value="../src/google/protobuf/unittest_mset.proto" />
    107                   <arg value="src/test/java/com/google/protobuf/lazy_fields_lite.proto" />
    108                   <arg value="src/test/java/com/google/protobuf/lite_equals_and_hash.proto" />
    109                   <arg
    110                     value="src/test/java/com/google/protobuf/multiple_files_test.proto" />
    111                   <arg value="src/test/java/com/google/protobuf/nested_builders_test.proto" />
    112                   <arg value="src/test/java/com/google/protobuf/nested_extension.proto" />
    113                   <arg value="src/test/java/com/google/protobuf/nested_extension_lite.proto" />
    114                   <arg value="src/test/java/com/google/protobuf/non_nested_extension.proto" />
    115                   <arg value="src/test/java/com/google/protobuf/non_nested_extension_lite.proto" />
    116                   <arg value="src/test/java/com/google/protobuf/outer_class_name_test.proto" />
    117                   <arg value="src/test/java/com/google/protobuf/outer_class_name_test2.proto" />
    118                   <arg value="src/test/java/com/google/protobuf/outer_class_name_test3.proto" />
    119                   <arg value="src/test/java/com/google/protobuf/test_bad_identifiers.proto" />
    120                   <arg value="src/test/java/com/google/protobuf/test_check_utf8.proto" />
    121                   <arg value="src/test/java/com/google/protobuf/test_check_utf8_size.proto" />
    122                   <arg value="src/test/java/com/google/protobuf/test_custom_options.proto" />
    123                   <arg
    124                     value="../src/google/protobuf/unittest_optimize_for.proto" />
    125                   <arg
    126                     value="../src/google/protobuf/unittest_custom_options.proto" />
    127                   <arg value="../src/google/protobuf/unittest_lite.proto" />
    128                   <arg value="../src/google/protobuf/unittest_import_lite.proto" />
    129                   <arg value="../src/google/protobuf/unittest_import_public_lite.proto" />
    130                   <arg value="../src/google/protobuf/unittest_lite_imports_nonlite.proto" />
    131                   <arg value="../src/google/protobuf/unittest_enormous_descriptor.proto" />
    132                   <arg value="../src/google/protobuf/unittest_no_generic_services.proto" />
    133                 </exec>
    134 		<!-- java micro -->
    135                 <exec executable="../src/protoc">
    136                   <arg value="--javamicro_out=opt=speed,java_use_vector=false,java_package=google/protobuf/unittest_import_micro.proto|com.google.protobuf.micro,java_outer_classname=google/protobuf/unittest_import_micro.proto|UnittestImportMicro:target/generated-test-sources" />
    137                   <arg value="--proto_path=../src" />
    138                   <arg value="--proto_path=src/test/java" />
    139                   <arg value="../src/google/protobuf/unittest_micro.proto" />
    140                   <arg value="../src/google/protobuf/unittest_simple_micro.proto" />
    141                   <arg value="../src/google/protobuf/unittest_stringutf8_micro.proto" />
    142                   <arg value="../src/google/protobuf/unittest_recursive_micro.proto" />
    143                   <arg value="../src/google/protobuf/unittest_import_micro.proto" />
    144                   <arg value="../src/google/protobuf/unittest_single_micro.proto" />
    145                   <arg value="../src/google/protobuf/unittest_multiple_micro.proto" />
    146                   <arg value="../src/google/protobuf/unittest_multiple_nameclash_micro.proto" />
    147                 </exec>
    148 		<!-- java nano -->
    149                 <exec executable="../src/protoc">
    150                   <arg value="--javanano_out=
    151                                   java_package = google/protobuf/unittest_import_nano.proto|com.google.protobuf.nano.testimport,
    152                                   java_outer_classname = google/protobuf/unittest_import_nano.proto|UnittestImportNano,
    153                                   generate_equals = true
    154                                 :target/generated-test-sources" />
    155                   <arg value="--proto_path=../src" />
    156                   <arg value="--proto_path=src/test/java" />
    157                   <arg value="../src/google/protobuf/unittest_nano.proto" />
    158                   <arg value="../src/google/protobuf/unittest_simple_nano.proto" />
    159                   <arg value="../src/google/protobuf/unittest_stringutf8_nano.proto" />
    160                   <arg value="../src/google/protobuf/unittest_recursive_nano.proto" />
    161                   <arg value="../src/google/protobuf/unittest_import_nano.proto" />
    162                   <arg value="../src/google/protobuf/unittest_single_nano.proto" />
    163                   <arg value="../src/google/protobuf/unittest_multiple_nano.proto" />
    164                   <arg value="../src/google/protobuf/unittest_multiple_nameclash_nano.proto" />
    165                   <arg value="../src/google/protobuf/unittest_enum_class_nano.proto" />
    166                   <arg value="../src/google/protobuf/unittest_repeated_merge_nano.proto" />
    167                 </exec>
    168                 <exec executable="../src/protoc">
    169                   <arg value="--javanano_out=store_unknown_fields=true,generate_equals=true,generate_clone=true:target/generated-test-sources" />
    170                   <arg value="--proto_path=../src" />
    171                   <arg value="--proto_path=src/test/java" />
    172                   <arg value="../src/google/protobuf/unittest_extension_nano.proto" />
    173                 </exec>
    174                 <exec executable="../src/protoc">
    175                   <arg value="--javanano_out=store_unknown_fields=true,generate_equals=true,generate_clone=true:target/generated-test-sources" />
    176                   <arg value="--proto_path=../src" />
    177                   <arg value="--proto_path=src/test/java" />
    178                   <arg value="../src/google/protobuf/unittest_extension_singular_nano.proto" />
    179                 </exec>
    180                 <exec executable="../src/protoc">
    181                   <arg value="--javanano_out=store_unknown_fields=true,generate_equals=true,generate_clone=true:target/generated-test-sources" />
    182                   <arg value="--proto_path=../src" />
    183                   <arg value="--proto_path=src/test/java" />
    184                   <arg value="../src/google/protobuf/unittest_extension_repeated_nano.proto" />
    185                 </exec>
    186                 <exec executable="../src/protoc">
    187                   <arg value="--javanano_out=store_unknown_fields=true:target/generated-test-sources" />
    188                   <arg value="--proto_path=../src" />
    189                   <arg value="--proto_path=src/test/java" />
    190                   <arg value="../src/google/protobuf/unittest_extension_packed_nano.proto" />
    191                 </exec>
    192                 <exec executable="../src/protoc">
    193                   <arg value="--javanano_out=store_unknown_fields=true:target/generated-test-sources" />
    194                   <arg value="--proto_path=../src" />
    195                   <arg value="--proto_path=src/test/java" />
    196                   <arg value="../src/google/protobuf/unittest_unknown_enum_values_nano.proto" />
    197                 </exec>
    198                 <exec executable="../src/protoc">
    199                   <arg value="--javanano_out=java_nano_generate_has=true,generate_equals=true:target/generated-test-sources" />
    200                   <arg value="--proto_path=../src" />
    201                   <arg value="--proto_path=src/test/java" />
    202                   <arg value="../src/google/protobuf/unittest_has_nano.proto" />
    203                 </exec>
    204                 <exec executable="../src/protoc">
    205                   <arg value="--javanano_out=optional_field_style=accessors,generate_equals=true:target/generated-test-sources" />
    206                   <arg value="--proto_path=../src" />
    207                   <arg value="--proto_path=src/test/java" />
    208                   <arg value="../src/google/protobuf/unittest_accessors_nano.proto" />
    209                 </exec>
    210                 <exec executable="../src/protoc">
    211                   <arg value="--javanano_out=enum_style=java:target/generated-test-sources" />
    212                   <arg value="--proto_path=../src" />
    213                   <arg value="--proto_path=src/test/java" />
    214                   <arg value="../src/google/protobuf/unittest_enum_class_nano.proto" />
    215                   <arg value="../src/google/protobuf/unittest_enum_class_multiple_nano.proto" />
    216                   <arg value="../src/google/protobuf/unittest_repeated_packables_nano.proto" />
    217                   <arg value="../src/google/protobuf/unittest_enum_validity_nano.proto" />
    218                 </exec>
    219                 <exec executable="../src/protoc">
    220                   <arg value="--javanano_out=
    221                                   optional_field_style=accessors,
    222                                   java_outer_classname=google/protobuf/unittest_enum_validity_nano.proto|EnumValidityAccessors
    223                                 :target/generated-test-sources" />
    224                   <arg value="--proto_path=../src" />
    225                   <arg value="--proto_path=src/test/java" />
    226                   <arg value="../src/google/protobuf/unittest_enum_validity_nano.proto" />
    227                 </exec>
    228                 <exec executable="../src/protoc">
    229                   <arg value="--javanano_out=optional_field_style=reftypes,generate_equals=true:target/generated-test-sources" />
    230                   <arg value="--proto_path=../src" />
    231                   <arg value="--proto_path=src/test/java" />
    232                   <arg value="../src/google/protobuf/unittest_reference_types_nano.proto" />
    233                 </exec>
    234                 <exec executable="../src/protoc">
    235                   <arg value="--javanano_out=optional_field_style=reftypes_compat_mode,generate_equals=true,java_outer_classname=google/protobuf/unittest_reference_types_nano.proto|NanoReferenceTypesCompat:target/generated-test-sources" />
    236                   <arg value="--proto_path=../src" />
    237                   <arg value="--proto_path=src/test/java" />
    238                   <arg value="../src/google/protobuf/unittest_reference_types_nano.proto" />
    239                 </exec>
    240                 <exec executable="../src/protoc">
    241                   <arg value="--javanano_out=bytes_offset_length=true:target/generated-test-sources" />
    242                   <arg value="--proto_path=../src" />
    243                   <arg value="--proto_path=src/test/java" />
    244                   <arg value="../src/google/protobuf/unittest_bytes_offset_length_nano.proto" />
    245                 </exec>
    246               </tasks>
    247               <testSourceRoot>target/generated-test-sources</testSourceRoot>
    248             </configuration>
    249             <goals>
    250               <goal>run</goal>
    251             </goals>
    252           </execution>
    253         </executions>
    254       </plugin>
    255       <plugin>
    256         <groupId>org.apache.felix</groupId>
    257         <artifactId>maven-bundle-plugin</artifactId>
    258         <extensions>true</extensions>
    259         <configuration>
    260           <instructions>
    261             <Bundle-DocURL>https://developers.google.com/protocol-buffers/</Bundle-DocURL>
    262             <Bundle-SymbolicName>com.google.protobuf</Bundle-SymbolicName>
    263             <Export-Package>com.google.protobuf;version=2.6.1</Export-Package>
    264           </instructions>
    265         </configuration>
    266       </plugin>
    267     </plugins>
    268   </build>
    269   <profiles>
    270     <profile>
    271       <id>lite</id>
    272       <build>
    273         <plugins>
    274           <plugin>
    275             <artifactId>maven-compiler-plugin</artifactId>
    276             <configuration>
    277               <includes>
    278                 <include>**/AbstractMessageLite.java</include>
    279                 <include>**/ByteString.java</include>
    280                 <include>**/CodedInputStream.java</include>
    281                 <include>**/CodedOutputStream.java</include>
    282                 <include>**/ExtensionRegistryLite.java</include>
    283                 <include>**/FieldSet.java</include>
    284                 <include>**/GeneratedMessageLite.java</include>
    285                 <include>**/Internal.java</include>
    286                 <include>**/InvalidProtocolBufferException.java</include>
    287                 <include>**/LazyStringArrayList.java</include>
    288                 <include>**/LazyStringList.java</include>
    289                 <include>**/MessageLite.java</include>
    290                 <include>**/MessageLiteOrBuilder.java</include>
    291                 <include>**/SmallSortedMap.java</include>
    292                 <include>**/UninitializedMessageException.java</include>
    293                 <include>**/UnmodifiableLazyStringList.java</include>
    294                 <include>**/WireFormat.java</include>
    295                 <include>**/Parser.java</include>
    296                 <include>**/AbstractParser.java</include>
    297                 <include>**/BoundedByteString.java</include>
    298                 <include>**/LiteralByteString.java</include>
    299                 <include>**/RopeByteString.java</include>
    300                 <include>**/Utf8.java</include>
    301                 <include>**/LazyField.java</include>
    302                 <include>**/LazyFieldLite.java</include>
    303                 <include>**/ProtocolStringList.java</include>
    304               </includes>
    305               <testIncludes>
    306                 <testInclude>**/LiteTest.java</testInclude>
    307                 <testInclude>**/*Lite.java</testInclude>
    308               </testIncludes>
    309             </configuration>
    310           </plugin>
    311           <plugin>
    312             <artifactId>maven-surefire-plugin</artifactId>
    313             <configuration>
    314               <includes>
    315                 <include>**/LiteTest.java</include>
    316               </includes>
    317             </configuration>
    318           </plugin>
    319           <plugin>
    320             <artifactId>maven-jar-plugin</artifactId>
    321             <configuration>
    322               <classifier>lite</classifier>
    323             </configuration>
    324           </plugin>
    325         </plugins>
    326       </build>
    327     </profile>
    328     <profile>
    329       <id>micro</id>
    330       <build>
    331         <plugins>
    332           <plugin>
    333             <artifactId>maven-compiler-plugin</artifactId>
    334             <configuration>
    335               <includes>
    336                 <include>**/MessageMicro.java</include>
    337                 <include>**/ByteStringMicro.java</include>
    338                 <include>**/CodedInputStreamMicro.java</include>
    339                 <include>**/CodedOutputStreamMicro.java</include>
    340                 <include>**/InvalidProtocolBufferMicroException.java</include>
    341                 <include>**/WireFormatMicro.java</include>
    342               </includes>
    343               <testIncludes>
    344                 <testInclude>**/MicroTest.java</testInclude>
    345                 <testInclude>**/MicroOuterClass.java</testInclude>
    346                 <testInclude>**/SimpleMessageMicro.java</testInclude>
    347                 <testInclude>**/StringUtf8.java</testInclude>
    348                 <testInclude>**/RecursiveMessageMicro.java</testInclude>
    349                 <testInclude>**/UnittestImportMicro.java</testInclude>
    350               </testIncludes>
    351             </configuration>
    352           </plugin>
    353           <plugin>
    354             <artifactId>maven-surefire-plugin</artifactId>
    355             <configuration>
    356               <includes>
    357                 <include>**/MicroTest.java</include>
    358               </includes>
    359             </configuration>
    360           </plugin>
    361           <plugin>
    362             <artifactId>maven-jar-plugin</artifactId>
    363             <configuration>
    364               <classifier>micro</classifier>
    365             </configuration>
    366           </plugin>
    367         </plugins>
    368       </build>
    369     </profile>
    370     <profile>
    371       <id>nano</id>
    372       <build>
    373         <plugins>
    374           <plugin>
    375             <artifactId>maven-compiler-plugin</artifactId>
    376             <configuration>
    377               <includes>
    378                 <include>**/MessageNano.java</include>
    379                 <include>**/CodedInputByteBufferNano.java</include>
    380                 <include>**/CodedOutputByteBufferNano.java</include>
    381                 <include>**/InternalNano.java</include>
    382                 <include>**/InvalidProtocolBufferNanoException.java</include>
    383                 <include>**/WireFormatNano.java</include>
    384               </includes>
    385               <testIncludes>
    386                 <testInclude>**/NanoTest.java</testInclude>
    387                 <testInclude>**/NanoOuterClass.java</testInclude>
    388                 <testInclude>**/SimpleMessageNano.java</testInclude>
    389                 <testInclude>**/StringUtf8.java</testInclude>
    390                 <testInclude>**/RecursiveMessageNano.java</testInclude>
    391                 <testInclude>**/UnittestImportNano.java</testInclude>
    392               </testIncludes>
    393             </configuration>
    394           </plugin>
    395           <plugin>
    396             <artifactId>maven-surefire-plugin</artifactId>
    397             <configuration>
    398               <includes>
    399                 <include>**/NanoTest.java</include>
    400               </includes>
    401             </configuration>
    402           </plugin>
    403           <plugin>
    404             <artifactId>maven-jar-plugin</artifactId>
    405             <configuration>
    406               <classifier>nano</classifier>
    407             </configuration>
    408           </plugin>
    409         </plugins>
    410       </build>
    411     </profile>
    412   </profiles>
    413 </project>
    414