MantisBT - CMake
View Issue Details
0010701CMakeCPackpublic2010-05-11 04:142011-07-08 17:54
Eric NOULARD 
Eric NOULARD 
normalfeaturealways
closedfixed 
CMake-2-8 
CMake 2.8.3CMake 2.8.3 
0010701: Lack of "%doc, %config, Obsolete" in CPackRPM
This is a reminder for a patch proposal sent on the ML:
http://www.cmake.org/pipermail/cmake/2010-May/036841.html [^]

Basically some missing features are wanted:
 * Lack of support for file names containing spaces
 * Lack of support for %config and %config(noreplace)
 * Lack of support for "Obsoletes:"
 * Lack of support for %doc

No tags attached.
related to 0010294closed Eric NOULARD Patch for CPack RPM generator (CPACK_RPM_SPEC_IGNORE_FILES) 
related to 0010345closed Eric NOULARD [Patch] CPackRPM: file path with spaces 
related to 0010741closed Eric NOULARD Some enhancements to the RPM generator [PATCH] 
related to 0007000closed Eric NOULARD CPack RPM generator should always "CPACK_SET_DESTDIR" 
related to 0010935closed Eric NOULARD Lack of support for relocatable package 
related to 0009932closed Eric NOULARD RPM Generator, spaces in CPACK_PACKAGE_NAME cause error while creating RPM archive 
related to 0010871closed Eric NOULARD CPackRPM-generated spec file won't accept spaces in file paths. 
diff bug10701-ErwanLegrand-CPackRPM.cmake.diff (4,598) 2010-05-11 04:17
https://public.kitware.com/Bug/file/3103/bug10701-ErwanLegrand-CPackRPM.cmake.diff
Issue History
2010-05-11 04:14Eric NOULARDNew Issue
2010-05-11 04:16Eric NOULARDRelationship addedrelated to 0010294
2010-05-11 04:17Eric NOULARDRelationship addedrelated to 0010345
2010-05-11 04:17Eric NOULARDFile Added: bug10701-ErwanLegrand-CPackRPM.cmake.diff
2010-05-11 04:18Eric NOULARDNote Added: 0020707
2010-05-11 04:22Eric NOULARDStatusnew => assigned
2010-05-11 04:22Eric NOULARDAssigned To => Eric NOULARD
2010-05-11 12:28J. BedouetNote Added: 0020710
2010-05-11 12:29J. BedouetNote Edited: 0020710
2010-05-11 12:30J. BedouetNote Edited: 0020710
2010-05-11 12:33J. BedouetNote Edited: 0020710
2010-07-04 07:09Eric NOULARDRelationship addedrelated to 0010741
2010-07-04 07:09Eric NOULARDNote Added: 0021223
2010-07-04 09:14Eric NOULARDRelationship addedrelated to 0009932
2010-07-04 09:14Eric NOULARDRelationship addedrelated to 0010871
2010-07-04 09:16Eric NOULARDNote Added: 0021227
2010-07-04 10:52Eric NOULARDRelationship addedrelated to 0007000
2010-07-04 10:54Eric NOULARDNote Added: 0021230
2010-07-04 11:08Eric NOULARDRelationship addedrelated to 0010935
2010-07-04 11:08Eric NOULARDNote Added: 0021231
2010-11-12 14:16Eric NOULARDNote Added: 0023219
2010-11-12 14:16Eric NOULARDStatusassigned => resolved
2010-11-12 14:16Eric NOULARDFixed in Version => CMake 2.8.3
2010-11-12 14:16Eric NOULARDResolutionopen => fixed
2010-11-12 14:16Eric NOULARDStatusresolved => closed
2011-07-08 17:54David ColeTarget Version => CMake 2.8.3

Notes
(0020707)
Eric NOULARD   
2010-05-11 04:18   
Attached proposed patch,
Added relationship with other bugs
(0020710)
J. Bedouet   
2010-05-11 12:28   
(edited on: 2010-05-11 12:33)
I would like to add an other missing feature:
 * Lack of support for relocatable package

To make a relocatable package, you have to add a tag "Prefix: " whose the value is generally the CMake prefix.


If I mimic the Buildarch tag, it would be something like that

# CPACK_RPM_PACKAGE_PREFIX (optional)
IF(CPACK_RPM_PACKAGE_PREFIX)
  SET(TMP_RPM_PREFIX "Prefix: ${CPACK_RPM_PACKAGE_PREFIX}")
  IF(CPACK_RPM_PACKAGE_DEBUG)
    MESSAGE("CPackRPM:Debug: using user-specified prefix (for relocatable package) = ${CPACK_RPM_PACKAGE_PREFIX}")
  ENDIF(CPACK_RPM_PACKAGE_DEBUG)
ELSE(CPACK_RPM_PACKAGE_PREFIX)
  SET(TMP_RPM_BUILDARCH "")
ENDIF(CPACK_RPM_PACKAGE_PREFIX)


and adding \@TMP_RPM_PREFIX\@ after \@TMP_RPM_BUILDARCH\@ in the specfile template.

It's not tested but it's very similar to Buildarch tag.

For more specific information, see Maximum RPM (http://www.rpm.org/max-rpm/ch-rpm-reloc.html [^] ).


Please, tell me if I must create a new issue but it's very similar to this one. Thanks.

(0021223)
Eric NOULARD   
2010-07-04 07:09   
bug 10741 did fix the support for Obsoletes
(0021227)
Eric NOULARD   
2010-07-04 09:16   
The space in filename issue has been merged to next.

commit 53899460dfb1aef50ad3bb7acd1ec30d618cc5e7
Merge: 5858e6d 6926e91
Author: Eric NOULARD <eric.noulard@gmail.com>
Date: Sun Jul 4 15:10:18 2010 +0200

    Merge branch 'CPackRPM-handleFileWithSpace' into next

commit 6926e9114c832607bdad97827bb918cb21ab231d
Author: Eric NOULARD <eric.noulard@gmail.com>
Date: Sun Jul 4 14:05:25 2010 +0200

    CPackRPM:: Quote every filenames in %file section (see bugs 10701,10871,10345)
(0021230)
Eric NOULARD   
2010-07-04 10:54   
Concerning the %config and %config(noreplace)
there is a neat interaction with the DESTDIR handling and absolute path name...
I'm afraid that the issue of DESTDIR and absolute path name should be handled
first and then I'll try to cope with %config...

Added relation with bug 7000 which is the one to be solved in the first place.
(my opinion)
(0021231)
Eric NOULARD   
2010-07-04 11:08   
I did create a separate 10935 bug in order to handle the relocatable
feature request separately
(0023219)
Eric NOULARD   
2010-11-12 14:16   
A small part of this bug remains which is the (noreplace) handling
this will be done in bug 0010294
http://public.kitware.com/Bug/view.php?id=10294 [^]