MantisBT - CMake
View Issue Details
0011873CMakeCPackpublic2011-02-16 17:132012-01-22 16:39
yorjo 
Eric NOULARD 
normalminoralways
closedwon't fix 
CMake-2-8 
 
0011873: [CPackRPM] %files section in spec file directories
CPackRPM doesn't handle symlink directories correctly

For example, my expected directory structured should be:

find -type f -o -type l | sed {s/\\.//}
/lib64/libmccparser.so
/lib64/libmccparser.so.2.0.0
/include/mccparser
/include/mccparser-2.0.0/Version.h
/include/mccparser-2.0.0/mccparser.h

where /include/mccparser is a symlink to /include/mccparser-2.0.0:

However, the produced RPM doesn't include the symlink directory:
rpm -qpl mccparser-2.0.0.rpm
/usr/include/mccparser-2.0.0/Version.h
/usr/include/mccparser-2.0.0/mccparser.h
/usr/lib64/libmccparser.so
/usr/lib64/libmccparser.so.2.0.0

with the side effect that the mccparler-2.0.0 directory is not deleted with an rpm --erase mccparser
Using cmake-2.8.2

No tags attached.
Issue History
2011-02-16 17:13yorjoNew Issue
2011-02-16 17:14yorjoNote Added: 0025454
2011-02-17 03:14Eric NOULARDAssigned To => Eric NOULARD
2011-02-17 03:14Eric NOULARDStatusnew => assigned
2011-02-17 03:51Eric NOULARDNote Added: 0025456
2011-09-20 14:36Eric NOULARDNote Added: 0027464
2011-09-20 14:36Eric NOULARDStatusassigned => feedback
2012-01-22 16:39Eric NOULARDNote Added: 0028390
2012-01-22 16:39Eric NOULARDStatusfeedback => closed
2012-01-22 16:39Eric NOULARDResolutionopen => won't fix

Notes
(0025454)
yorjo   
2011-02-16 17:14   
This must be related to the 0009654 issue
(0025456)
Eric NOULARD   
2011-02-17 03:51   
Hi,

CPack is using just the same find command:
"find -type f -o -type l"

Could you attached the spec file produced by CPack in your buggy case?
This is the file printed out during CPack run:
CPackRPM: Will use GENERATED spec file: /DATA/ERIC/CMake/CMake-gitted/build/_CPack_Packages/Linux-i686/RPM/SPECS/cmake.spec

The question is does /include/mccparser appear in the %file list ?

I'm not sure that CPackRPM is the culprit, may be rpmbuild is doing something
nasty in this case.

In the meantime you may recreate the symlinks using postinstall script
embbeded in the rpm see:
CPACK_RPM_POST_INSTALL_SCRIPT_FILE
CPACK_RPM_POST_UNINSTALL_SCRIPT_FILE


Would you be able to provide a small self-contained example project
which exhibits the issue?
(0027464)
Eric NOULARD   
2011-09-20 14:36   
I need more information on this since
I wasn't able to reproduce the issue with current CMake master
(2.8.6rc3)
(0028390)
Eric NOULARD   
2012-01-22 16:39   
Closing because I did not have any feedback after 3 monthes.