Re: [cmake-developers] [CPack][BUG] Fail to package with CPACK_INSTALLED_DIRECTORIES

2015-09-25 Thread Domen Vrankar
2015-09-24 9:06 GMT+02:00 Domen Vrankar :
> 2015-09-23 17:00 GMT+02:00 CHEVRIER, Marc :
>> Any comments about this problem?

There was a bug in file creation time handling. Fix is in cmake git
repository on next branch:
http://cmake.org/gitweb?p=cmake.git;a=commit;h=39347d3

Could you check if it works for you?

Thanks,
Domen
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


Re: [cmake-developers] [CPack][BUG] Fail to package with CPACK_INSTALLED_DIRECTORIES

2015-09-25 Thread CHEVRIER, Marc

Hi Domen,

Good news! With your patch, packaging on Windows is now working as expected.
Thank you.

Marc




On 25/09/15 10:34, "Domen Vrankar"  wrote:

>2015-09-24 9:06 GMT+02:00 Domen Vrankar :
>> 2015-09-23 17:00 GMT+02:00 CHEVRIER, Marc :
>>> Any comments about this problem?
>
>There was a bug in file creation time handling. Fix is in cmake git
>repository on next branch:
>http://cmake.org/gitweb?p=cmake.git;a=commit;h=39347d3
>
>Could you check if it works for you?
>
>Thanks,
>Domen
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


Re: [cmake-developers] [CPack][BUG] Fail to package with CPACK_INSTALLED_DIRECTORIES

2015-09-24 Thread Domen Vrankar
2015-09-23 17:00 GMT+02:00 CHEVRIER, Marc :
> Any comments about this problem?

Sorry I've forgotten about this mail... From what you're describing it
should work. I'll take a look later today and get back to you then.

Thanks,
Domen
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


[cmake-developers] [CPack][BUG] Fail to package with CPACK_INSTALLED_DIRECTORIES

2015-09-15 Thread CHEVRIER, Marc

Hi,

To enable to handle various packages as part of the same project and to avoid 
to execute preinstall target before packaging, I rely on CPack variables 
CPACK_INSTALLED_DIRECTORIES and CPACK_INSTALL_COMMANDS.

Unfortunately, packaging is failing in the following conditions:

  *   Platform Windows (regardless generator: test done with “Visual Studio” 
and "Ninja”)
  *   Install command with PERMISSIONS read-only (like OWNER_READ)
  *   PROJECT command with LANGUAGES CXX (specifying LANGUAGES NONE is OK !??)

In this case, installed read-only files cannot be copied by CPack.

Attached is a CMakeLists.txt showing the problem:

  *   Target package-OK generates the expected package (no read-only 
permissions)
  *   Target package-KO fails to generate the package (same as previous one 
except read-only permissions)

Marc


cmake_minimum_required (VERSION 3.1)

project (TEST LANGUAGES CXX)

install (FILES file.h PERMISSIONS OWNER_READ GROUP_READ WORLD_READ DESTINATION 
include COMPONENT KO)

install (FILES file.h DESTINATION include COMPONENT OK)


set (CPACK_GENERATOR "TGZ")

set (install_prefix ${CMAKE_SOURCE_DIR}/INSTALL)

set (KO_install_command "${CMAKE_COMMAND} 
-DCMAKE_INSTALL_PREFIX=${install_prefix} -DCOMPONENT=KO -DBUILD_TYPE=$ 
-P ${CMAKE_BINARY_DIR}/cmake_install.cmake")

add_custom_target (package-KO COMMAND "${CMAKE_CPACK_COMMAND}" -C $ -D 
CPACK_COMPONENTS_ALL=KO -D CPACK_INSTALL_COMMANDS=${KO_install_command} -D 
CPACK_INSTALLED_DIRECTORIES=${install_prefix}$. --config 
./CPackConfig.cmake)


set (OK_install_command "${CMAKE_COMMAND} 
-DCMAKE_INSTALL_PREFIX=${install_prefix} -DCOMPONENT=OK -DBUILD_TYPE=$ 
-P ${CMAKE_BINARY_DIR}/cmake_install.cmake")

add_custom_target (package-OK COMMAND "${CMAKE_CPACK_COMMAND}" -C $ -D 
CPACK_COMPONENTS_ALL=OK -D CPACK_INSTALL_COMMANDS=${OK_install_command} -D 
CPACK_INSTALLED_DIRECTORIES=${install_prefix}$. --config 
./CPackConfig.cmake)

include (CPack)
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers