Correct CMake Warning Messages - QCustomPlot, QHexEdit

Correct text case usage in local FindXXX.cmake and CMakeLists.txt files.
During usage, warning messages appear due to differences in file name/library name case.

Resolution is to match file name case with variable name case where it appears in all CMake files.
i.e. file name - QCustomPlot.cmake
     variable name QCustomPlot_{LIBRARIES, INCLUDE_DIRS, et al}

Affects CMakeLists.txt and cmake/FindXXX.cmake files.
This commit is contained in:
Scott Furry
2020-04-23 04:43:56 -06:00
parent f791c32896
commit 4e7669bd0c
3 changed files with 43 additions and 43 deletions

View File

@@ -75,12 +75,12 @@ if(NOT FORCE_INTERNAL_QSCINTILLA)
find_package(QScintilla 2.8.10 QUIET)
endif()
if(FORCE_INTERNAL_QCUSTOMPLOT)
set(QCUSTOMPLOT_FOUND FALSE)
set(QCustomPlot_FOUND FALSE)
else()
find_package(QCustomPlot)
endif()
if(FORCE_INTERNAL_QHEXEDIT)
set(QHEXEDIT_FOUND FALSE)
set(QHexEdit_FOUND FALSE)
else()
find_package(QHexEdit)
endif()
@@ -90,15 +90,15 @@ if(NOT QSCINTILLA_FOUND)
set(QSCINTILLA_DIR libs/qscintilla/Qt4Qt5)
add_subdirectory(${QSCINTILLA_DIR})
endif()
if(NOT QHEXEDIT_FOUND)
set(QHEXEDIT_DIR libs/qhexedit)
set(QHEXEDIT_INCL_DIR ${QHEXEDIT_DIR}/src)
add_subdirectory(${QHEXEDIT_DIR})
if(NOT QHexEdit_FOUND)
set(QHexEdit_DIR libs/qhexedit)
set(QHexEdit_INCL_DIR ${QHexEdit_DIR}/src)
add_subdirectory(${QHexEdit_DIR})
endif()
add_subdirectory(${JSON_DIR})
if(NOT QCUSTOMPLOT_FOUND)
set(QCUSTOMPLOT_DIR libs/qcustomplot-source)
add_subdirectory(${QCUSTOMPLOT_DIR})
if(NOT QCustomPlot_FOUND)
set(QCustomPlot_DIR libs/qcustomplot-source)
add_subdirectory(${QCustomPlot_DIR})
endif()
set(CMAKE_AUTOMOC ON)
@@ -386,15 +386,15 @@ include_directories(
${JSON_DIR}
${ADDITIONAL_INCLUDE_PATHS}
src)
if(QHEXEDIT_FOUND)
include_directories(${QHEXEDIT_INCLUDE_DIR})
if(QHexEdit_FOUND)
include_directories(${QHexEdit_INCLUDE_DIR})
else()
include_directories(${QHEXEDIT_INCL_DIR})
include_directories(${QHexEdit_INCL_DIR})
endif()
if(QCUSTOMPLOT_FOUND)
include_directories(${QCUSTOMPLOT_INCLUDE_DIR})
if(QCustomPlot_FOUND)
include_directories(${QCustomPlot_INCLUDE_DIR})
else()
include_directories(${QCUSTOMPLOT_DIR})
include_directories(${QCustomPlot_DIR})
endif()
if(QSCINTILLA_FOUND)
include_directories(${QSCINTILLA_INCLUDE_DIR})
@@ -420,21 +420,21 @@ if (ALL_WARNINGS AND CMAKE_COMPILER_IS_GNUCC)
endif()
endif()
if(NOT QHEXEDIT_FOUND)
if(NOT QHexEdit_FOUND)
add_dependencies(${PROJECT_NAME} qhexedit)
endif()
if(NOT QCUSTOMPLOT_FOUND)
if(NOT QCustomPlot_FOUND)
add_dependencies(${PROJECT_NAME} qcustomplot)
endif()
if(NOT QSCINTILLA_FOUND)
add_dependencies(${PROJECT_NAME} qscintilla2)
endif()
if(NOT QHEXEDIT_FOUND)
link_directories("${CMAKE_CURRENT_BINARY_DIR}/${QHEXEDIT_DIR}")
if(NOT QHexEdit_FOUND)
link_directories("${CMAKE_CURRENT_BINARY_DIR}/${QHexEdit_DIR}")
endif()
if(NOT QCUSTOMPLOT_FOUND)
link_directories("${CMAKE_CURRENT_BINARY_DIR}/${QCUSTOMPLOT_DIR}")
if(NOT QCustomPlot_FOUND)
link_directories("${CMAKE_CURRENT_BINARY_DIR}/${QCustomPlot_DIR}")
endif()
if(NOT QSCINTILLA_FOUND)
link_directories("${CMAKE_CURRENT_BINARY_DIR}/${QSCINTILLA_DIR}")
@@ -448,13 +448,13 @@ target_link_libraries(${PROJECT_NAME}
${WIN32_STATIC_LINK}
${LIBSQLITE}
${ADDITIONAL_LIBS})
if(QHEXEDIT_FOUND)
target_link_libraries(${PROJECT_NAME} ${QHEXEDIT_LIBRARIES})
if(QHexEdit_FOUND)
target_link_libraries(${PROJECT_NAME} ${QHexEdit_LIBRARIES})
else()
target_link_libraries(${PROJECT_NAME} qhexedit)
endif()
if(QCUSTOMPLOT_FOUND)
target_link_libraries(${PROJECT_NAME} ${QCUSTOMPLOT_LIBRARIES})
if(QCustomPlot_FOUND)
target_link_libraries(${PROJECT_NAME} ${QCustomPlot_LIBRARIES})
else()
target_link_libraries(${PROJECT_NAME} qcustomplot)
endif()

View File

@@ -31,21 +31,21 @@
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
find_library(QCUSTOMPLOT_LIBRARY qcustomplot)
set(QCUSTOMPLOT_LIBRARIES "${QCUSTOMPLOT_LIBRARY}")
find_library(QCustomPlot_LIBRARY qcustomplot)
set(QCustomPlot_LIBRARIES "${QCustomPlot_LIBRARY}")
find_path(QCUSTOMPLOT_INCLUDE_DIR qcustomplot.h)
set(QCUSTOMPLOT_INCLUDE_DIRS "${QCUSTOMPLOT_INCLUDE_DIR}")
find_path(QCustomPlot_INCLUDE_DIR qcustomplot.h)
set(QCustomPlot_INCLUDE_DIRS "${QCustomPlot_INCLUDE_DIR}")
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(
QCUSTOMPLOT
QCustomPlot
DEFAULT_MSG
QCUSTOMPLOT_LIBRARIES
QCUSTOMPLOT_INCLUDE_DIRS
QCustomPlot_LIBRARIES
QCustomPlot_INCLUDE_DIRS
)
mark_as_advanced(
QCUSTOMPLOT_INCLUDE_DIRS
QCUSTOMPLOT_LIBRARIES
QCustomPlot_INCLUDE_DIRS
QCustomPlot_LIBRARIES
)

View File

@@ -31,21 +31,21 @@
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
find_library(QHEXEDIT_LIBRARY qhexedit)
set(QHEXEDIT_LIBRARIES "${QHEXEDIT_LIBRARY}")
find_library(QHexEdit_LIBRARY qhexedit)
set(QHexEdit_LIBRARIES "${QHexEdit_LIBRARY}")
find_path(QHEXEDIT_INCLUDE_DIR qhexedit.h)
set(QHEXEDIT_INCLUDE_DIRS "${QHEXEDIT_INCLUDE_DIR}")
find_path(QHexEdit_INCLUDE_DIR qhexedit.h)
set(QHexEdit_INCLUDE_DIRS "${QHexEdit_INCLUDE_DIR}")
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(
QHEXEDIT
QHexEdit
DEFAULT_MSG
QHEXEDIT_LIBRARIES
QHEXEDIT_INCLUDE_DIRS
QHexEdit_LIBRARIES
QHexEdit_INCLUDE_DIRS
)
mark_as_advanced(
QHEXEDIT_INCLUDE_DIRS
QHEXEDIT_LIBRARIES
QHexEdit_INCLUDE_DIRS
QHexEdit_LIBRARIES
)