Skip to content
This repository has been archived by the owner on Jun 7, 2021. It is now read-only.

[TRAFODION-3241]support maven compilation with both jdk1.7 and jdk1.8 #1779

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/conn/jdbcT4/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ all: build_all
build_all: target/jdbcT4-${TRAFODION_VER}.jar

target/jdbcT4-${TRAFODION_VER}.jar: $(java_files) LICENSE NOTICE
echo "$(MAVEN) package -DskipTests"
@echo "$(MAVEN) package -DskipTests"
set -o pipefail && $(MAVEN) install -Dhttps.protocols=TLSv1,TLSv1.1,TLSv1.2 -DskipTests | tee build_jdbct4.log | grep --line-buffered -E -e '^\[[^WId]' -e '^\[INFO\] B[Uu][Ii][Ll][Dd]' -e 'to compile'
cp target/jdbcT4-${TRAFODION_VER}.jar ${TRAF_HOME}/export/lib
mkdir -p ../clients
Expand Down
13 changes: 13 additions & 0 deletions core/conn/jdbcT4/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,15 @@
</plugins>
</build>
<profiles>
<profile>
<id>disable-javadoc-doclint</id>
<activation>
<jdk>[1.8,)</jdk>
</activation>
<properties>
<javadoc.opts>-Xdoclint:none</javadoc.opts>
</properties>
</profile>
<profile>
<id>apache-release</id>
<activation>
Expand Down Expand Up @@ -286,6 +295,10 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.9</version>
<configuration>
<docfilessubdirs>true</docfilessubdirs>
<additionalparam>${javadoc.opts}</additionalparam>
</configuration>
<executions>
<execution>
<id>attach-javadocs</id>
Expand Down
19 changes: 10 additions & 9 deletions dcs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,24 +26,25 @@ BLD_TRAFODION_DCS_TARNAME =dcs-$(TRAFODION_VER).tar.gz

VFILE =trafodion-dcs.jar.versions
GENVERS =./genvers
java_files:=$(shell find src/main/java -name *.java*|grep -v Vproc.java)

.NOTPARALLEL: all

all: build_all
all: target/dcs-$(TRAFODION_VER).jar

build_all: build_chk
echo "$(MAVEN) site package -DskipTests"
echo "### For full Maven output, see file build_dcs.log"
set -o pipefail && $(MAVEN) site package -DskipTests | tee build_dcs.log | grep --line-buffered -E -e '^\[[^WId]' -e '^\[INFO\] B[Uu][Ii][Ll][Dd]' -e 'to compile'
$(RM) $(VFILE)

build_chk:
target/dcs-$(TRAFODION_VER).jar: $(java_files)
$(GENVERS) > $(VFILE)
@if [ $(GENVERS) -nt target/$(BLD_TRAFODION_DCS_TARNAME) ]; then echo "update manifest"; $(RM) -f target/$(BLD_TRAFODION_DCS_TARNAME); fi
@if [ $(TRAF_HOME)/export/include/SCMBuildStr.h -nt target/$(BLD_TRAFODION_DCS_TARNAME) ]; then echo "update manifest"; $(RM) -f target/$(BLD_TRAFODION_DCS_TARNAME); fi
@echo "$(MAVEN) site package -DskipTests"
@echo "### For full Maven output, see file build_dcs.log"
set -o pipefail && $(MAVEN) site package -DskipTests | tee build_dcs.log | grep --line-buffered -E -e '^\[[^WId]' -e '^\[INFO\] B[Uu][Ii][Ll][Dd]' -e 'to compile'
$(RM) $(VFILE)

clean:
mvn_clean:
-$(MAVEN) clean | grep ERROR

clean: $(shell if [ -d target ]; then echo "mvn_clean"; fi)
$(RM) build_dcs.log
$(RM) $(VFILE)
$(RM) ../${DISTRIBUTION_DIR}/$(BLD_TRAFODION_DCS_TARNAME)
18 changes: 16 additions & 2 deletions dcs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,8 @@
<version>2.5.1</version>
<inherited>true</inherited>
<configuration>
<source>1.7</source>
<target>1.7</target>
<source>${source.version}</source>
<target>${target.version}</target>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -527,6 +527,8 @@
<surefire.skipSecondPart>true</surefire.skipSecondPart>
<surefire.firstPartGroups>org.trafodion.dcs.SmallTests</surefire.firstPartGroups>
<surefire.secondPartGroups>org.trafodion.dcs.MediumTests, org.trafodion.dcs.LargeTests</surefire.secondPartGroups>
<source.version>1.7</source.version>
<target.version>1.7</target.version>

</properties>

Expand Down Expand Up @@ -654,6 +656,17 @@
<profiles>
<!-- JDBC drivers needed for compile, but not site docs
This allows turning off dependency on command line (-P '!jdbc') -->
<profile>
<id>disable-javadoc-doclint</id>
<activation>
<jdk>[1.8,)</jdk>
</activation>
<properties>
<javadoc.opts>-Xdoclint:none</javadoc.opts>
<source.version>1.8</source.version>
<target.version>1.8</target.version>
</properties>
</profile>
<profile>
<id>jdbc</id>
<activation>
Expand Down Expand Up @@ -742,6 +755,7 @@
<version>${maven.javadoc.plugin.version}</version>
<configuration>
<docfilessubdirs>true</docfilessubdirs>
<additionalparam>${javadoc.opts}</additionalparam>
</configuration>
<reportSets>
<reportSet>
Expand Down