Re: [CMake] .so link and cpack

2017-04-09 Thread Gonzalo Garramuño



El 09/04/17 a las 07:13, Eric Noulard escribió:

Hi Gonzalo,

You should be able to build Deb package including symlink without trouble.

Could you give the exact sequence of dpkg command which leads to the 
error you are speaking of?



$ dpkg -i mrViewer-v3.5.8-Linux-64.deb
(Leyendo la base de datos ... 309470 ficheros o directorios instalados 
actualmente.)

Preparando para desempaquetar mrViewer-v3.5.8-Linux-64.deb ...
Desempaquetando mrviewer (3.5.8) sobre (3.5.8) ...
dpkg: error al procesar el archivo mrViewer-v3.5.8-Linux-64.deb (--install):
 el tamaño del enlace simbólico 
'/usr/local/mrViewer-v3.5.8-Linux-64/lib/libACESclip.so' ha cambiado de 
48 a 20


Does it work ok if you uninstall the previously installed deb package 
first?



Yes.
Do you install the very same package twice or did you change somehow 
the package version?


I install a different revision of the same version of the package. So it 
unpacks v3.5.8 over v3.5.8


I think the problem is that I am installing it into an NTFS partition.  
I have both Ubuntu 12.04 and Ubuntu 16.04.1 and the problem appears on 
Ubuntu 16.04, which has its /usr/local pointing to a NTFS partition.

Sorry for the noise.
--

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

Re: [CMake] .so link and cpack

2017-04-09 Thread Eric Noulard
Hi Gonzalo,

You should be able to build Deb package including symlink without trouble.

Could you give the exact sequence of dpkg command which leads to the error
you are speaking of?

Does it work ok if you uninstall the previously installed deb package first?

Do you install the very same package twice or did you change somehow the
package version?


Le 8 avr. 2017 19:28, "Gonzalo Garramuño"  a écrit :

Currently, I have a project where I build a library and an executable that
depends on the library.  Finally, I package a .deb package with cpack.

Now, my problem is that cpack packs the symbolic link of my library and
that creates problems with the deb installer ( dpkg -i ) whenever I try to
install the same version of my program twice. The error I get is that the
symbolic link changed value from 20 to 42 (or something like that).

I tried removing the symbolic link previous to packaging, but then I get
cpack erroring out with:

CMake Error at /media/gga/Datos/code/applications/mrViewer/BUILD/Linux-3.
13.0-108-generic-64/Release/tmp/libACESclip/cmake_install.cmake:47 (file):
  file INSTALL cannot find
"/media/gga/Datos/code/applications/mrViewer/BUILD/Linux-3.
13.0-108-generic-64/Release/lib/libACESclip.so".

Following a post on stackoverflow, I also tried using NAMELINK_SKIP on the
library, like:


set_target_properties( ACESclip
  PROPERTIES
  SOVERSION ${SOVERSION})

install( TARGETS ACESclip
  RUNTIME DESTINATION bin
  LIBRARY DESTINATION lib
  ARCHIVE DESTINATION lib
  NAMELINK_SKIP )

But then the executable:

ADD_EXECUTABLE( mrViewer WIN32 ${SOURCES} )
TARGET_LINK_LIBRARIES( mrViewer ${LIBRARIES} ACESclip )

would not find my library and would error out.

Therefore, I turn to the list for help.  How do I prevent cpack from
packaging symbolic links (a feature which is kind of wrong at least for
.deb files)?  Or how do I make my executable use the library without
symlinks?

Thanks in advance.


-- 

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/opensou
rce/opensource.html

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

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