mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-05 04:40:31 +09:00
Set the cmake project verision to the autogenerated file to have a single point to set the version. This will be included in the libssh.h file. Pair-Programmed-With: Andreas Schneider <asn@cryptomilk.org> Signed-off-by: Heiko Thiery <heiko.thiery@gmail.com> Signed-off-by: Andreas Schneider <asn@cryptomilk.org> Reviewed-by: Jakub Jelen <jjelen@redhat.com>
42 lines
1.6 KiB
CMake
42 lines
1.6 KiB
CMake
/*
|
|
* This file is part of the SSH Library
|
|
*
|
|
* Copyright (c) 2020 by Heiko Thiery
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
* License as published by the Free Software Foundation; either
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Lesser General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
* License along with this library; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
*/
|
|
|
|
#ifndef _LIBSSH_VERSION_H
|
|
#define _LIBSSH_VERSION_H
|
|
|
|
/* libssh version macros */
|
|
#define SSH_VERSION_INT(a, b, c) ((a) << 16 | (b) << 8 | (c))
|
|
#define SSH_VERSION_DOT(a, b, c) a ##.## b ##.## c
|
|
#define SSH_VERSION(a, b, c) SSH_VERSION_DOT(a, b, c)
|
|
|
|
/* libssh version */
|
|
#define LIBSSH_VERSION_MAJOR @libssh_VERSION_MAJOR@
|
|
#define LIBSSH_VERSION_MINOR @libssh_VERSION_MINOR@
|
|
#define LIBSSH_VERSION_MICRO @libssh_VERSION_PATCH@
|
|
|
|
#define LIBSSH_VERSION_INT SSH_VERSION_INT(LIBSSH_VERSION_MAJOR, \
|
|
LIBSSH_VERSION_MINOR, \
|
|
LIBSSH_VERSION_MICRO)
|
|
#define LIBSSH_VERSION SSH_VERSION(LIBSSH_VERSION_MAJOR, \
|
|
LIBSSH_VERSION_MINOR, \
|
|
LIBSSH_VERSION_MICRO)
|
|
|
|
#endif /* _LIBSSH_VERSION_H */
|