Skip to content

Commit

Permalink
WIP: update Java's classpath
Browse files Browse the repository at this point in the history
Signed-off-by: Aviv Litman <alitman@redhat.com>
  • Loading branch information
avlitman committed May 10, 2022
1 parent 2a058d7 commit 8eee342
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ install-packaging-files: \
$(MAKE) copy-recursive SOURCEDIR=packaging/sys-etc TARGETDIR="$(DESTDIR)$(SYSCONF_DIR)" EXCLUDE_GEN="$(GENERATED)"
$(MAKE) copy-recursive SOURCEDIR=packaging/etc TARGETDIR="$(DESTDIR)$(PKG_SYSCONF_DIR)" EXCLUDE_GEN="$(GENERATED)"
$(MAKE) copy-recursive SOURCEDIR=packaging/setup TARGETDIR="$(DESTDIR)$(PKG_DATA_DIR)/../ovirt-engine/setup" EXCLUDE_GEN="$(GENERATED)"
for d in bin conf dbscripts etl services wildflydom4jjavaconf; do \
for d in bin conf dbscripts etl services wildflyjavaconf; do \
$(MAKE) copy-recursive SOURCEDIR="packaging/$${d}" TARGETDIR="$(DESTDIR)$(PKG_DATA_DIR)/$${d}" EXCLUDE_GEN="$(GENERATED)"; \
done

Expand Down
11 changes: 7 additions & 4 deletions packaging/bin/dwh-classpath.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ if [ -z "${JAVA_HOME}" ]; then
export JAVA_HOME
fi

if [ -z "${WILDFLYDOM4JJAVACONF}" ]; then
WILDFLYDOM4JJAVACONFDIR="$(readlink -f $(dirname $(dirname $0)))/wildflydom4jjavaconf"
if [ -z "${WILDFLYJAVACONF}" ]; then
WILDFLYJAVACONFDIR="$(readlink -f $(dirname $(dirname $0)))/wildflyjavaconf"
fi

if [ -x /usr/bin/java-config ]; then
Expand All @@ -47,20 +47,23 @@ if [ -x /usr/bin/java-config ]; then
done
elif [ -x /usr/bin/build-classpath ]; then
dom4j="$(build-classpath dom4j 2> /dev/null)"
[ -z "${dom4j}" ] && dom4j="$(build-classpath dom4j-eap6 2> /dev/null)"
[ -z "${dom4j}" ] && dom4j="$(JAVACONFDIRS=${WILDFLYDOM4JJAVACONFDIR} build-classpath dom4j 2> /dev/null)"
[ -z "${dom4j}" ] && dom4j="$(JAVACONFDIRS=${WILDFLYJAVACONFDIR} build-classpath dom4j 2> /dev/null)"
[ -n "${dom4j}" ] || die "Cannot find dom4j"
commons_collections="$(build-classpath apache-commons-collections 2> /dev/null)"
[ -z "${commons_collections}" ] && commons_collections="$(build-classpath commons-collections 2> /dev/null)"
[ -z "${commons_collections}" ] && commons_collections="$(JAVACONFDIRS=${WILDFLYJAVACONFDIR} build-classpath commons-collections 2> /dev/null)"
[ -n "${commons_collections}" ] || die "Cannot find commons-collections"
jackson_core="$(build-classpath jackson-core 2> /dev/null)"
[ -z "${jackson_core}" ] && jackson_core="$(build-classpath jackson-core 2> /dev/null)"
[ -z "${jackson_core}" ] && jackson_core="$(JAVACONFDIRS=${WILDFLYJAVACONFDIR} build-classpath jackson-core 2> /dev/null)"
[ -n "${jackson_core}" ] || die "Cannot find jackson-core"
jackson_databind="$(build-classpath jackson-databind 2> /dev/null)"
[ -z "${jackson_databind}" ] && jackson_databind="$(build-classpath jackson-databind 2> /dev/null)"
[ -z "${jackson_databind}" ] && jackson_databind="$(JAVACONFDIRS=${WILDFLYJAVACONFDIR} build-classpath jackson-databind 2> /dev/null)"
[ -n "${jackson_databind}" ] || die "Cannot find jackson-databind"
jackson_annotations="$(build-classpath jackson-annotations 2> /dev/null)"
[ -z "${jackson_annotations}" ] && jackson_annotations="$(build-classpath jackson-annotations 2> /dev/null)"
[ -z "${jackson_annotations}" ] && jackson_annotations="$(JAVACONFDIRS=${WILDFLYJAVACONFDIR} build-classpath jackson-annotations 2> /dev/null)"
[ -n "${jackson_annotations}" ] || die "Cannot find jackson-annotations"
if [ "${what}" = "run" ]; then
postgresql_jdbc="$(build-classpath postgresql-jdbc)" || die "Canot find postgreql-jdbc"
Expand Down
1 change: 0 additions & 1 deletion packaging/wildflydom4jjavaconf/java.conf

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
This directory contains a java.conf file to point java's build_classpath to wildfly's dom4j.
This directory contains a java.conf file to point java's build_classpath.
1 change: 1 addition & 0 deletions packaging/wildflyjavaconf/java.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
JAVA_LIBDIR=/usr/share/ovirt-engine-wildfly/modules/system/layers/base:/opt/rh/eap7/root/usr/share/java:/opt/rh/eap7/root/usr/share/wildfly/modules/system/layers/base

0 comments on commit 8eee342

Please sign in to comment.