mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-07 22:02:12 +08:00
build: fix JAMI_REVISION, JAMI_DIRTY_REPO
Change-Id: I879224318b47c151db91a12c0260dea25e33553d
This commit is contained in:
@ -2,8 +2,8 @@
|
|||||||
|
|
||||||
src=$(abs_top_srcdir)
|
src=$(abs_top_srcdir)
|
||||||
|
|
||||||
RING_DIRTY_REPO ?= $(shell git diff-index --quiet HEAD 2>/dev/null || echo dirty)
|
JAMI_DIRTY_REPO ?= $(shell git diff-index --quiet HEAD 2>/dev/null || echo dirty)
|
||||||
RING_REVISION ?= $(shell git log -1 --format="%h" --abbrev=10 2>/dev/null)
|
JAMI_REVISION ?= $(shell git log -1 --format="%h" --abbrev=10 2>/dev/null)
|
||||||
JAMI_DATADIR ?= $(datadir)/jami
|
JAMI_DATADIR ?= $(datadir)/jami
|
||||||
|
|
||||||
# Preprocessor flags
|
# Preprocessor flags
|
||||||
@ -17,7 +17,7 @@ AM_CPPFLAGS += \
|
|||||||
-DPREFIX=\"$(prefix)\" \
|
-DPREFIX=\"$(prefix)\" \
|
||||||
-DJAMI_DATADIR=\"$(JAMI_DATADIR)\" \
|
-DJAMI_DATADIR=\"$(JAMI_DATADIR)\" \
|
||||||
-DENABLE_TRACE \
|
-DENABLE_TRACE \
|
||||||
-LIBJAMI_REVISION=\"$(RING_REVISION)\" \
|
-DJAMI_REVISION=\"$(JAMI_REVISION)\" \
|
||||||
-LIBJAMI_DIRTY_REPO=\"$(RING_DIRTY_REPO)\" \
|
-DJAMI_DIRTY_REPO=\"$(JAMI_DIRTY_REPO)\" \
|
||||||
-DPJSIP_MAX_PKT_LEN=8000 \
|
-DPJSIP_MAX_PKT_LEN=8000 \
|
||||||
-DPJ_AUTOCONF=1
|
-DPJ_AUTOCONF=1
|
||||||
|
@ -27,12 +27,12 @@
|
|||||||
|
|
||||||
#include <ciso646> // fix windows compiler bug
|
#include <ciso646> // fix windows compiler bug
|
||||||
|
|
||||||
#ifndef RING_REVISION
|
#ifndef JAMI_REVISION
|
||||||
#define RING_REVISION ""
|
#define JAMI_REVISION ""
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef RING_DIRTY_REPO
|
#ifndef JAMI_DIRTY_REPO
|
||||||
#define RING_DIRTY_REPO ""
|
#define JAMI_DIRTY_REPO ""
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef PACKAGE_VERSION
|
#ifndef PACKAGE_VERSION
|
||||||
@ -44,9 +44,9 @@ namespace libjami {
|
|||||||
const char*
|
const char*
|
||||||
version() noexcept
|
version() noexcept
|
||||||
{
|
{
|
||||||
return RING_REVISION[0] and RING_DIRTY_REPO[0]
|
return JAMI_REVISION[0] and JAMI_DIRTY_REPO[0]
|
||||||
? PACKAGE_VERSION "-" RING_REVISION "-" RING_DIRTY_REPO
|
? PACKAGE_VERSION "-" JAMI_REVISION "-" JAMI_DIRTY_REPO
|
||||||
: (RING_REVISION[0] ? PACKAGE_VERSION "-" RING_REVISION : PACKAGE_VERSION);
|
: (JAMI_REVISION[0] ? PACKAGE_VERSION "-" JAMI_REVISION : PACKAGE_VERSION);
|
||||||
}
|
}
|
||||||
|
|
||||||
const char*
|
const char*
|
||||||
|
Reference in New Issue
Block a user