--- CMakeLists.txt
+++ CMakeLists.txt
@@ -14,7 +14,7 @@ option(EASYHTTPCPP_VERBOSE_MESSAGES "Enable informational messages during config
 set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
 set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
 set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
-set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
-
+set(PROJECT_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
+set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${PROJECT_MODULE_PATH})
 if (WIN32)
     if (NOT FORCE_SHAREDLIB)
@@ -52,12 +53,12 @@ if (FORCE_SHAREDLIB)
     set(CMAKE_POSITION_INDEPENDENT_CODE ON)
     set(LIB_MODE SHARED)
     if (EASYHTTPCPP_VERBOSE_MESSAGES)
-        message(STATUS "Building shared ${CMAKE_PROJECT_NAME} libraries")
+        message(STATUS "Building shared ${PROJECT_NAME} libraries")
     endif ()
 else ()
     set(LIB_MODE STATIC)
     if (EASYHTTPCPP_VERBOSE_MESSAGES)
-        message(STATUS "Building static ${CMAKE_PROJECT_NAME} libraries")
+        message(STATUS "Building static ${PROJECT_NAME} libraries")
     endif ()
 endif ()
 
@@ -170,19 +170,19 @@ endif ()
 
 include(CMakePackageConfigHelpers)
 write_basic_package_version_file(
-        "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}ConfigVersion.cmake"
+        "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}ConfigVersion.cmake"
         VERSION ${PROJECT_VERSION}
         COMPATIBILITY AnyNewerVersion
 )
 
 configure_file(cmake/DefineProjectConfig.cmake.in
-               "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}Config.cmake" @ONLY)
+               "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}Config.cmake" @ONLY)
 install(
         FILES
-        ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}Config.cmake
-        ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}ConfigVersion.cmake
+        ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}Config.cmake
+        ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}ConfigVersion.cmake
         DESTINATION
-        "lib/cmake/${CMAKE_PROJECT_NAME}"
+        "lib/cmake/${PROJECT_NAME}"
         COMPONENT
         Devel
 )
--- cmake/DefineProjectConfig.cmake.in
+++ cmake/DefineProjectConfig.cmake.in
@@ -1,49 +1,49 @@
 if (CMAKE_VERSION VERSION_LESS 3.0)
-    message(FATAL_ERROR "@CMAKE_PROJECT_NAME@ requires at least CMake version 3.0")
+    message(FATAL_ERROR "@PROJECT_NAME@ requires at least CMake version 3.0")
 endif ()
 
-set(_@CMAKE_PROJECT_NAME@_FIND_PARTS_REQUIRED)
-if (@CMAKE_PROJECT_NAME@_FIND_REQUIRED)
-    set(_@CMAKE_PROJECT_NAME@_FIND_PARTS_REQUIRED REQUIRED)
+set(_@PROJECT_NAME@_FIND_PARTS_REQUIRED)
+if (@PROJECT_NAME@_FIND_REQUIRED)
+    set(_@PROJECT_NAME@_FIND_PARTS_REQUIRED REQUIRED)
 endif ()
-set(_@CMAKE_PROJECT_NAME@_FIND_PARTS_QUIET)
-if (@CMAKE_PROJECT_NAME@_FIND_QUIETLY)
-    set(_@CMAKE_PROJECT_NAME@_FIND_PARTS_QUIET QUIET)
+set(_@PROJECT_NAME@_FIND_PARTS_QUIET)
+if (@PROJECT_NAME@_FIND_QUIETLY)
+    set(_@PROJECT_NAME@_FIND_PARTS_QUIET QUIET)
 endif ()
 
-get_filename_component(_@CMAKE_PROJECT_NAME@_install_prefix "${CMAKE_CURRENT_LIST_DIR}" ABSOLUTE)
+get_filename_component(_@PROJECT_NAME@_install_prefix "${CMAKE_CURRENT_LIST_DIR}" ABSOLUTE)
 
-set(_@CMAKE_PROJECT_NAME@_NOTFOUND_MESSAGE)
+set(_@PROJECT_NAME@_NOTFOUND_MESSAGE)
 
-set(_@CMAKE_PROJECT_NAME@_CMAKE_PREFIX_PATH_old ${CMAKE_PREFIX_PATH})
-set(CMAKE_PREFIX_PATH ${_@CMAKE_PROJECT_NAME@_install_prefix})
+set(_@PROJECT_NAME@_CMAKE_PREFIX_PATH_old ${CMAKE_PREFIX_PATH})
+set(CMAKE_PREFIX_PATH ${_@PROJECT_NAME@_install_prefix})
 
 set(module @LIBRARY_TARGET_NAME@)
-find_package(@CMAKE_PROJECT_NAME@${module}
-             ${_@CMAKE_PROJECT_NAME@_FIND_PARTS_QUIET}
-             ${_@CMAKE_PROJECT_NAME@_FIND_PARTS_REQUIRED}
-             PATHS "${_@CMAKE_PROJECT_NAME@_install_prefix}" NO_DEFAULT_PATH
+find_package(@PROJECT_NAME@${module}
+             ${_@PROJECT_NAME@_FIND_PARTS_QUIET}
+             ${_@PROJECT_NAME@_FIND_PARTS_REQUIRED}
+             PATHS "${_@PROJECT_NAME@_install_prefix}" NO_DEFAULT_PATH
              )
-if (NOT @CMAKE_PROJECT_NAME@${module}_FOUND)
-    if (@CMAKE_PROJECT_NAME@_FIND_REQUIRED_${module})
-        set(_@CMAKE_PROJECT_NAME@_NOTFOUND_MESSAGE
-            "${_@CMAKE_PROJECT_NAME@_NOTFOUND_MESSAGE}Failed to find @CMAKE_PROJECT_NAME@ component \"${module}\" config file at \"${_@CMAKE_PROJECT_NAME@_install_prefix}/@CMAKE_PROJECT_NAME@${module}/@CMAKE_PROJECT_NAME@${module}Config.cmake\"\n")
-    elseif (NOT @CMAKE_PROJECT_NAME@_FIND_QUIETLY)
-        message(WARNING "Failed to find @CMAKE_PROJECT_NAME@ component \"${module}\" config file at \"${_@CMAKE_PROJECT_NAME@_install_prefix}/@CMAKE_PROJECT_NAME@${module}/@CMAKE_PROJECT_NAME@${module}Config.cmake\"")
+if (NOT @PROJECT_NAME@${module}_FOUND)
+    if (@PROJECT_NAME@_FIND_REQUIRED_${module})
+        set(_@PROJECT_NAME@_NOTFOUND_MESSAGE
+            "${_@PROJECT_NAME@_NOTFOUND_MESSAGE}Failed to find @PROJECT_NAME@ component \"${module}\" config file at \"${_@PROJECT_NAME@_install_prefix}/@PROJECT_NAME@${module}/@PROJECT_NAME@${module}Config.cmake\"\n")
+    elseif (NOT @PROJECT_NAME@_FIND_QUIETLY)
+        message(WARNING "Failed to find @PROJECT_NAME@ component \"${module}\" config file at \"${_@PROJECT_NAME@_install_prefix}/@PROJECT_NAME@${module}/@PROJECT_NAME@${module}Config.cmake\"")
     endif ()
 endif ()
 
 # For backward compatibility set the LIBRARIES variable
-list(APPEND @CMAKE_PROJECT_NAME@_LIBRARIES "@CMAKE_PROJECT_NAME@::${module}")
+list(APPEND @PROJECT_NAME@_LIBRARIES "@PROJECT_NAME@::${module}")
 
 # For backward compatibility set the INCLUDE_DIR(s) variables
-list(APPEND @CMAKE_PROJECT_NAME@_INCLUDE_DIR "@CMAKE_INSTALL_PREFIX@/include")
-list(APPEND @CMAKE_PROJECT_NAME@_INCLUDE_DIRS "@CMAKE_INSTALL_PREFIX@/include")
+list(APPEND @PROJECT_NAME@_INCLUDE_DIR "@CMAKE_INSTALL_PREFIX@/include")
+list(APPEND @PROJECT_NAME@_INCLUDE_DIRS "@CMAKE_INSTALL_PREFIX@/include")
 
 # Restore the original CMAKE_PREFIX_PATH value
-set(CMAKE_PREFIX_PATH ${_@CMAKE_PROJECT_NAME@_CMAKE_PREFIX_PATH_old})
+set(CMAKE_PREFIX_PATH ${_@PROJECT_NAME@_CMAKE_PREFIX_PATH_old})
 
-if (_@CMAKE_PROJECT_NAME@_NOTFOUND_MESSAGE)
-    set(@CMAKE_PROJECT_NAME@_NOT_FOUND_MESSAGE "${_@CMAKE_PROJECT_NAME@_NOTFOUND_MESSAGE}")
-    set(@CMAKE_PROJECT_NAME@_FOUND False)
+if (_@PROJECT_NAME@_NOTFOUND_MESSAGE)
+    set(@PROJECT_NAME@_NOT_FOUND_MESSAGE "${_@PROJECT_NAME@_NOTFOUND_MESSAGE}")
+    set(@PROJECT_NAME@_FOUND False)
 endif ()
--- cmake/DefineProjectMacros.cmake
+++ cmake/DefineProjectMacros.cmake
@@ -9,34 +9,34 @@
 macro(easyhttpcpp_generate_package target_name)
     include(CMakePackageConfigHelpers)
     write_basic_package_version_file(
-            "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}${target_name}ConfigVersion.cmake"
+            "${PROJECT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}${target_name}ConfigVersion.cmake"
             VERSION ${PROJECT_VERSION}
             COMPATIBILITY AnyNewerVersion
     )
     export(EXPORT "${target_name}Targets"
-           FILE "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}${target_name}Targets.cmake"
-           NAMESPACE "${CMAKE_PROJECT_NAME}::"
+           FILE "${PROJECT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}${target_name}Targets.cmake"
+           NAMESPACE "${PROJECT_NAME}::"
            )
 
-    configure_file("${CMAKE_MODULE_PATH}/${CMAKE_PROJECT_NAME}${target_name}Config.cmake.in"
-                   "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}${target_name}Config.cmake"
+    configure_file("${PROJECT_MODULE_PATH}/${PROJECT_NAME}${target_name}Config.cmake.in"
+                   "${PROJECT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}${target_name}Config.cmake"
                    @ONLY
                    )
 
-    set(ConfigPackageLocation "lib/cmake/${CMAKE_PROJECT_NAME}")
+    set(ConfigPackageLocation "lib/cmake/${PROJECT_NAME}")
 
     install(
             EXPORT "${target_name}Targets"
-            FILE "${CMAKE_PROJECT_NAME}${target_name}Targets.cmake"
-            NAMESPACE "${CMAKE_PROJECT_NAME}::"
-            DESTINATION "lib/cmake/${CMAKE_PROJECT_NAME}"
+            FILE "${PROJECT_NAME}${target_name}Targets.cmake"
+            NAMESPACE "${PROJECT_NAME}::"
+            DESTINATION "lib/cmake/${PROJECT_NAME}"
     )
 
     install(
             FILES
-            "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}${target_name}Config.cmake"
-            "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}/${CMAKE_PROJECT_NAME}${target_name}ConfigVersion.cmake"
-            DESTINATION "lib/cmake/${CMAKE_PROJECT_NAME}"
+            "${PROJECT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}${target_name}Config.cmake"
+            "${PROJECT_BINARY_DIR}/${PROJECT_NAME}/${PROJECT_NAME}${target_name}ConfigVersion.cmake"
+            DESTINATION "lib/cmake/${PROJECT_NAME}"
             COMPONENT Devel
     )
 endmacro()
--- cmake/DefineProjectVersion.cmake
+++ cmake/DefineProjectVersion.cmake
@@ -12,7 +12,7 @@
 
 if (EASYHTTPCPP_VERBOSE_MESSAGES)
     message(STATUS)
-    message(STATUS "################# ${CMAKE_PROJECT_NAME} version details #################")
+    message(STATUS "################# ${PROJECT_NAME} version details #################")
 endif ()
 
 file(STRINGS "${PROJECT_SOURCE_DIR}/libversion" SHARED_LIBRARY_VERSION)
@@ -22,7 +22,7 @@ file(STRINGS "${PROJECT_SOURCE_DIR}/VERSION" PACKAGE_VERSION)
 add_definitions(-DPACKAGE_VERSION=${PACKAGE_VERSION})
 
 if (EASYHTTPCPP_VERBOSE_MESSAGES)
-    message(STATUS "${CMAKE_PROJECT_NAME} package version: ${PACKAGE_VERSION}")
+    message(STATUS "${PROJECT_NAME} package version: ${PACKAGE_VERSION}")
 endif ()
 
 string(REGEX REPLACE "([0-9]+)\\.[0-9]+\\.[0-9]+.*" "\\1" CPACK_PACKAGE_VERSION_MAJOR ${PACKAGE_VERSION})
@@ -41,16 +41,16 @@ add_definitions(-DPACKAGE_VERSION_PATCH=${CPACK_PACKAGE_VERSION_PATCH})
 add_definitions(-DPACKAGE_VERSION_EXT=${CPACK_PACKAGE_VERSION_EXT})
 
 if (EASYHTTPCPP_VERBOSE_MESSAGES)
-    message(STATUS "${CMAKE_PROJECT_NAME} package version major: ${CPACK_PACKAGE_VERSION_MAJOR}")
-    message(STATUS "${CMAKE_PROJECT_NAME} package version minor: ${CPACK_PACKAGE_VERSION_MINOR}")
-    message(STATUS "${CMAKE_PROJECT_NAME} package version patch: ${CPACK_PACKAGE_VERSION_PATCH}")
-    message(STATUS "${CMAKE_PROJECT_NAME} package version extensions: ${CPACK_PACKAGE_VERSION_EXT}")
+    message(STATUS "${PROJECT_NAME} package version major: ${CPACK_PACKAGE_VERSION_MAJOR}")
+    message(STATUS "${PROJECT_NAME} package version minor: ${CPACK_PACKAGE_VERSION_MINOR}")
+    message(STATUS "${PROJECT_NAME} package version patch: ${CPACK_PACKAGE_VERSION_PATCH}")
+    message(STATUS "${PROJECT_NAME} package version extensions: ${CPACK_PACKAGE_VERSION_EXT}")
 endif ()
 
 set(PROJECT_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH})
 
 if (EASYHTTPCPP_VERBOSE_MESSAGES)
-    message(STATUS "${CMAKE_PROJECT_NAME} project version: ${PROJECT_VERSION}")
-    message(STATUS "################# ${CMAKE_PROJECT_NAME} version details #################")
+    message(STATUS "${PROJECT_NAME} project version: ${PROJECT_VERSION}")
+    message(STATUS "################# ${PROJECT_NAME} version details #################")
     message(STATUS)
 endif ()
--- cmake/easyhttpcppeasyhttpConfig.cmake.in
+++ cmake/easyhttpcppeasyhttpConfig.cmake.in
@@ -1 +1 @@
-include("${CMAKE_CURRENT_LIST_DIR}/@CMAKE_PROJECT_NAME@@LIBRARY_TARGET_NAME@Targets.cmake")
\ No newline at end of file
+include("${CMAKE_CURRENT_LIST_DIR}/@PROJECT_NAME@@LIBRARY_TARGET_NAME@Targets.cmake")
--- doc/Doxyfile.in
+++ doc/Doxyfile.in
@@ -32,7 +32,7 @@ DOXYFILE_ENCODING      = UTF-8
 # title of most generated pages and in a few other places.
 # The default value is: My Project.
 
-PROJECT_NAME           = @CMAKE_PROJECT_NAME@
+PROJECT_NAME           = @PROJECT_NAME@
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number. This
 # could be handy for archiving the generated documentation or if some version
@@ -2424,4 +2424,4 @@ GENERATE_LEGEND        = YES
 # The default value is: YES.
 # This tag requires that the tag HAVE_DOT is set to YES.
 
-DOT_CLEANUP            = YES
\ No newline at end of file
+DOT_CLEANUP            = YES
--- samples/AsyncHttpClient/CMakeLists.txt
+++ samples/AsyncHttpClient/CMakeLists.txt
@@ -1,4 +1,4 @@
-set(SAMPLE_NAME "${CMAKE_PROJECT_NAME}-AsyncHttpClient")
+set(SAMPLE_NAME "${PROJECT_NAME}-AsyncHttpClient")
 
 set(SAMPLE_SRCS "AsyncHttpClient.cpp")
 
--- samples/SimpleHttpClient/CMakeLists.txt
+++ samples/SimpleHttpClient/CMakeLists.txt
@@ -1,4 +1,4 @@
-set(SAMPLE_NAME "${CMAKE_PROJECT_NAME}-SimpleHttpClient")
+set(SAMPLE_NAME "${PROJECT_NAME}-SimpleHttpClient")
 
 set(SAMPLE_SRCS "SimpleHttpClient.cpp")
 
