[LyX/2.4.2-1] Prepare for packaging
Enrico Forestieri
forenr at lyx.org
Wed Sep 25 10:42:56 UTC 2024
On Wed, Sep 25, 2024 at 11:59:54AM +0200, Pavel Sanda wrote:
>
>On Wed, Sep 25, 2024 at 10:48:59AM +0100, José Matos wrote:
>> For what is worth in the RPM world we use that dash to separate the
>> version from the release.
>
>Similarly in the .deb world the "-" is generally used for distro-related fixes,
>so staying with "." is a sane default.
Moreover, our configure machinery expects a version of type x.y.z.p and
the last digit (possibly missing) is assigned to LYX_RELEASE_PATCH).
See, for example, config/lyxinclude.m4:
...
dnl Extract the single digits from PACKAGE_VERSION and make them available.
dnl Defines LYX_MAJOR_VERSION, LYX_MINOR_VERSION, LYX_RELEASE_LEVEL,
dnl LYX_RELEASE_PATCH (possibly equal to 0), LYX_DIR_VER, and LYX_USERDIR_VER.
AC_DEFUN([LYX_SET_VERSION_INFO],
[lyx_major=`echo $PACKAGE_VERSION | sed -e 's/[[.]].*//'`
lyx_patch=`echo $PACKAGE_VERSION | sed -e "s/^$lyx_major//" -e 's/^.//'`
lyx_minor=`echo $lyx_patch | sed -e 's/[[.]].*//'`
lyx_patch=`echo $lyx_patch | sed -e "s/^$lyx_minor//" -e 's/^.//'`
lyx_release=`echo $lyx_patch | sed -e 's/[[^0-9]].*//'`
lyx_patch=`echo $lyx_patch | sed -e "s/^$lyx_release//" -e 's/^[[.]]//' -e 's/[[^0-9]].*//'`
test "x$lyx_patch" = "x" && lyx_patch=0
lyx_dir_ver=LYX_DIR_${lyx_major}${lyx_minor}x
lyx_userdir_ver=LYX_USERDIR_${lyx_major}${lyx_minor}x
AC_SUBST(LYX_MAJOR_VERSION,$lyx_major)
AC_SUBST(LYX_MINOR_VERSION,$lyx_minor)
AC_SUBST(LYX_RELEASE_LEVEL,$lyx_release)
AC_SUBST(LYX_RELEASE_PATCH,$lyx_patch)
AC_SUBST(LYX_DIR_VER,"$lyx_dir_ver")
AC_SUBST(LYX_USERDIR_VER,"$lyx_userdir_ver")
])
...
So, using x.y.z-p, LYX_RELEASE_PATCH will be assigned the value 0
instead of p.
--
Enrico
More information about the lyx-devel
mailing list