You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by gm...@apache.org on 2018/01/30 14:27:56 UTC
qpid-dispatch git commit: DISPATCH-921 Run npm install after
stand-alone console install. This closes #249
Repository: qpid-dispatch
Updated Branches:
refs/heads/master fe8e38bfb -> 0c1d568c8
DISPATCH-921 Run npm install after stand-alone console install. This closes #249
Project: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/commit/0c1d568c
Tree: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/tree/0c1d568c
Diff: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/diff/0c1d568c
Branch: refs/heads/master
Commit: 0c1d568c8ecf96b5e718bf9492d0c79baf65f215
Parents: fe8e38b
Author: Ernest Allen <ea...@redhat.com>
Authored: Mon Jan 29 11:53:49 2018 -0500
Committer: Ganesh Murthy <gm...@redhat.com>
Committed: Tue Jan 30 09:27:11 2018 -0500
----------------------------------------------------------------------
CMakeLists.txt | 2 +-
console/CMakeLists.txt | 51 ++++++++++++++++++++++++++++-----------------
2 files changed, 33 insertions(+), 20 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/0c1d568c/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 55c6e5f..ea97e15 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -37,7 +37,7 @@ option(QD_MEMORY_STATS "Track memory pool usage statistics" ON)
file(STRINGS "${CMAKE_SOURCE_DIR}/VERSION.txt" QPID_DISPATCH_VERSION)
-cmake_minimum_required(VERSION 2.6)
+cmake_minimum_required(VERSION 2.8.12)
include(CheckLibraryExists)
include(CheckSymbolExists)
include(CheckFunctionExists)
http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/0c1d568c/console/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/console/CMakeLists.txt b/console/CMakeLists.txt
index 7ff9333..db57125 100644
--- a/console/CMakeLists.txt
+++ b/console/CMakeLists.txt
@@ -25,12 +25,25 @@ set(CONSOLE_BASE_SOURCE_DIR "${CMAKE_SOURCE_DIR}/console/stand-alone/")
option(CONSOLE_INSTALL "Install stand-alone console" ON)
if(CONSOLE_INSTALL)
- # Static console files
- install(
- DIRECTORY ${CONSOLE_BASE_SOURCE_DIR}
+ # Static console files
+ install(
+ DIRECTORY ${CONSOLE_BASE_SOURCE_DIR}
DESTINATION ${CONSOLE_STAND_ALONE_INSTALL_DIR}
)
+ # run npm install for console if npm is installed
+ find_program(PROG_NPM npm)
+ if (PROG_NPM STREQUAL "PROG_NPM-NOTFOUND")
+ message(WARNING "Program npm not found. You must manually install console dependencies.")
+ else ()
+ message(STATUS "Program npm found. Console dependencies will be installed.")
+ install(
+ CODE "MESSAGE(\"Installing console dependencies with npm.\")")
+ install(
+ CODE "execute_process(COMMAND npm install
+ WORKING_DIRECTORY ${CONSOLE_STAND_ALONE_INSTALL_DIR})")
+ endif()
+
endif(CONSOLE_INSTALL)
##
@@ -38,20 +51,20 @@ endif(CONSOLE_INSTALL)
##
find_program (MAVEN_EXE mvn DOC "Location of the maven program")
if (MAVEN_EXE)
- # the directory where the .war file will be built
- set(HAWTIO_BUILD_DIR "${CMAKE_BINARY_DIR}/hawtio")
-
- # create the console .war file
- add_custom_target(hawtio
- COMMAND ${MAVEN_EXE} -DbuildDirectory=${HAWTIO_BUILD_DIR} package
- WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/console/hawtio
- )
-
- # install the built war file into the console dir
- install(
- # We don't know in advance what the name of the final .war will be because
- # the war file name depends on the version in the pom.xml. The version will change each release
- CODE "file( GLOB builtwar \"${HAWTIO_BUILD_DIR}/dispatch-hawtio-console*.war\" )"
- CODE "file( INSTALL \${builtwar} DESTINATION \"${CONSOLE_INSTALL_DIR}/hawtio\" )"
- )
+ # the directory where the .war file will be built
+ set(HAWTIO_BUILD_DIR "${CMAKE_BINARY_DIR}/hawtio")
+
+ # create the console .war file
+ add_custom_target(hawtio
+ COMMAND ${MAVEN_EXE} -DbuildDirectory=${HAWTIO_BUILD_DIR} package
+ WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/console/hawtio
+ )
+
+ # install the built war file into the console dir
+ install(
+ # We don't know in advance what the name of the final .war will be because
+ # the war file name depends on the version in the pom.xml. The version will change each release
+ CODE "file( GLOB builtwar \"${HAWTIO_BUILD_DIR}/dispatch-hawtio-console*.war\" )"
+ CODE "file( INSTALL \${builtwar} DESTINATION \"${CONSOLE_INSTALL_DIR}/hawtio\" )"
+ )
endif(MAVEN_EXE)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org