Commit b423f1a6 authored by Matt T. Proud's avatar Matt T. Proud

Rearrange Java building for Maven. :-(

parent 3398f942
......@@ -28,15 +28,22 @@ go: go/metrics.pb.go
go/metrics.pb.go: metrics.proto
protoc $< --go_out=go/
java: java/src/main/java/io/prometheus/client/Metrics.java
$(MAKE) -C java
java: src/main/java/io/prometheus/client/Metrics.java pom.xml
mvn clean compile package
java/src/main/java/io/prometheus/client/Metrics.java: metrics.proto
protoc $< --java_out=java/src/main/java
src/main/java/io/prometheus/client/Metrics.java: metrics.proto
protoc $< --java_out=src/main/java
python: python/metrics_pb2.py
python/metrics_pb2.py: metrics.proto
protoc $< --python_out=python/
.PHONY: all cpp go java python
clean:
-rm -rf cpp/*
-rm -rf go/*
-rm -rf java/*
-rm -rf python/*
-mvn clean
.PHONY: all clean cpp go java python
# Copyright 2013 Prometheus Team
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
all: stage
pom:
mvn clean
mvn compile
mvn package
stage: pom
mvn -DaltDeploymentRepository=snapshot-repo::default::file:$(PWD)/../io.prometheus-maven-repository/snapshots deploy
SUFFIXES:
.PHONY: pom stage
......@@ -50,13 +50,6 @@
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
......@@ -74,6 +67,12 @@
<goal>javadoc</goal>
</goals>
</execution>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
......@@ -82,10 +81,12 @@
<source>1.6</source>
<target>1.6</target>
</configuration>
<version>3.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.0.4</version>
<executions>
<execution>
<id>attach-sources</id>
......@@ -95,18 +96,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment