MantisBT - CMake
View Issue Details
0010871CMakeCPackpublic2010-06-24 10:242010-10-03 17:38
Luis Garrido 
Eric NOULARD 
normalminoralways
closedfixed 
CMake-2-6 
CMake 2.8.3CMake 2.8.3 
0010871: CPackRPM-generated spec file won't accept spaces in file paths.
If a file with spaces in its path is added to the %files section of the spec file it must be quoted, otherwise rpmbuild will fail with the message:

"error: Two files on one line"

I am using cmake-2.6.4-3.fc11.i586, but I installed a recent CPackRPM from git in the project tree to fix an incompatibility with Fedora 11 rpmbuild.
No tags attached.
related to 0010345closed Eric NOULARD [Patch] CPackRPM: file path with spaces 
related to 0010701closed Eric NOULARD Lack of "%doc, %config, Obsolete" in CPackRPM 
related to 0009932closed Eric NOULARD RPM Generator, spaces in CPACK_PACKAGE_NAME cause error while creating RPM archive 
related to 0011595closed Eric NOULARD CPack can't generate RPMs (on FC11) 
Issue History
2010-06-24 10:24Luis GarridoNew Issue
2010-07-03 05:43Eric NOULARDStatusnew => assigned
2010-07-03 05:43Eric NOULARDAssigned To => Eric NOULARD
2010-07-03 05:45Eric NOULARDNote Added: 0021216
2010-07-03 07:16Luis GarridoNote Added: 0021217
2010-07-03 08:35Rolf Eike BeerNote Added: 0021218
2010-07-04 04:59Eric NOULARDRelationship addedrelated to 0010345
2010-07-04 09:13Eric NOULARDRelationship addedrelated to 0009932
2010-07-04 09:14Eric NOULARDRelationship addedrelated to 0010701
2010-07-04 09:15Eric NOULARDNote Added: 0021225
2010-07-04 09:16Eric NOULARDNote Added: 0021226
2010-07-04 09:16Eric NOULARDStatusassigned => closed
2010-07-04 09:16Eric NOULARDResolutionopen => fixed
2010-07-04 09:16Eric NOULARDFixed in Version => CMake-2-8
2010-07-05 14:08Eric NOULARDNote Added: 0021241
2010-07-05 14:08Eric NOULARDStatusclosed => feedback
2010-07-05 14:08Eric NOULARDResolutionfixed => reopened
2010-07-05 14:08Eric NOULARDNote Added: 0021242
2010-07-05 14:08Eric NOULARDStatusfeedback => resolved
2010-07-05 14:08Eric NOULARDResolutionreopened => fixed
2010-09-10 00:05David ColeFixed in VersionCMake-2-8 => CMake 2.8.3
2010-09-10 00:05David ColeTarget Version => CMake 2.8.3
2010-10-03 17:38Eric NOULARDStatusresolved => closed
2010-12-11 05:19Eric NOULARDRelationship addedrelated to 0011595

Notes
(0021216)
Eric NOULARD   
2010-07-03 05:45   
I'll try to fix that but rpm and rpmbuild as trouble with space anyway.

For example currently you cannot build rpm if your build tree path
contains space because rpmbuild is not able to handle that.

May be you would be able to provide a standalone test case
(0021217)
Luis Garrido   
2010-07-03 07:16   
I am using CPack in this (quite small) project:

http://sourceforge.net/apps/trac/ls16 [^]
http://sourceforge.net/scm/?type=git&group_id=328996 [^]

There is a folder called "stylesheets/HighContrast" that was formerly named "stylesheets/High Contrast", thus making rpmbuild fail (and prompting me to file this report.) You are of course welcome to use it as a test case if it is of any help.

From what I gathered, I think an easy fix for this particular case would be to always double-quote the file names that are added to the %files section of the spec.
(0021218)
Rolf Eike Beer   
2010-07-03 08:35   
'"' is also a valid path character, so that needs to be quoted then, too. I don't expect it to work now...
(0021225)
Eric NOULARD   
2010-07-04 09:15   
The fix for bugs 10701,10871,10345 has been commited to next
(0021226)
Eric NOULARD   
2010-07-04 09:16   
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)
(0021241)
Eric NOULARD   
2010-07-05 14:08   
Prematurely closed
(0021242)
Eric NOULARD   
2010-07-05 14:08   
Prematurely closed