Am Sonntag 02 August 2009 schrieb Bruno Postle: > On Sat 01-Aug-2009 at 18:21 -0400, Yuval Levy wrote: > >> In this case, 2.0 is major+minor number and 30801 is the svn-revision. > > > >I think Bruno wanted to keep the patch version. Would a four digit > >version number work? major.minor.patch.svn? > > > >hugin-2009.1.0.4138-Linux.deb > > Putting the SVN number in the CMakeLists.txt file is a mess, you > change it, commit it and the SVN number changes again.
No, you can 'ask' the svn about the version number.
Like this:
FIND_PROGRAM(_svnversion svnversion)
message(STATUS "svnversion = ${_svnversion}")
if(NOT ${_svnversion} MATCHES "-NOTFOUND")
EXECUTE_PROCESS(COMMAND ${_svnversion} WORKING_DIRECTORY
"${TOP_SRC_DIR}"
OUTPUT_VARIABLE CPACK_RPM_PACKAGE_RELEASE OUTPUT_STRIP_TRAILING_WHITESPACE)
if(CPACK_RPM_PACKAGE_RELEASE MATCHES "^\([0-9]+\)")
set(CPACK_PACKAGE_VERSION_PATCH ${CMAKE_MATCH_1})
endif()
endif()
include(CPack)
> Automated packages such as those created by checkinstall or cpack
> don't have a fine-grained version. Packaging for distributions
> always involves incrementing a 'release; number, putting the svn
> number in the name is superfluous.
Hmmm, I am not creating a release :)
> >> 1.) I create them to install at /usr/local, which is not the "standard"
> >> place.
> >
> >oh, I forgot about those "standards". I love the /usr/local way, like in
> >FreeBSD.
>
> Generally /usr should only contain stuff tracked by the package
> manager and /usr/local should only contain stuff manually installed.
> This way you can always `rm -rf /usr/local` if it all goes wrong -
> Manually deleting or chnaging files from a deb/rpm package is really
> going to break stuff.
Kornel
--
Kornel Benko
[email protected]
signature.asc
Description: This is a digitally signed message part.
