Skip to content
Permalink
Browse files

folloup CMakeLists.txt updates (followup eddf6fe)

  • Loading branch information
jef-n authored and 3nids committed Nov 12, 2020
1 parent 9631806 commit b5e9df9033fd14937706120102e7853b8dd94823
Showing with 23 additions and 23 deletions.
  1. +3 −3 .ci/azure-pipelines/azure-pipelines.yml
  2. +3 −3 debian/rules
  3. +4 −4 ms-windows/osgeo4w/creatensis.pl
  4. +3 −3 rpm/buildrpms.sh
  5. +8 −8 scripts/release.pl
  6. +2 −2 scripts/tsstat.pl
@@ -71,9 +71,9 @@ jobs:
esac
target=Experimental
major=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_MAJOR "\([0-9]*\)")\s*$/\1/p' CMakeLists.txt)
minor=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_MINOR "\([0-9]*\)")\s*$/\1/p' CMakeLists.txt)
patch=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_PATCH "\([0-9]*\)")\s*$/\1/p' CMakeLists.txt)
major=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_MAJOR "\([0-9]*\)")\s*$/\1/ip' CMakeLists.txt)
minor=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_MINOR "\([0-9]*\)")\s*$/\1/ip' CMakeLists.txt)
patch=$(sed -ne 's/^SET(CPACK_PACKAGE_VERSION_PATCH "\([0-9]*\)")\s*$/\1/ip' CMakeLists.txt)
binary=$(curl --location-trusted http://ftp.osuosl.org/pub/osgeo/download/osgeo4w/$OSGEO4W_ARCH/release/qgis/$OSGEO4W_PKG/LATEST.sha | sed -e "s/:.*$//")
(( binary++ )) || true
@@ -46,9 +46,9 @@ endif

DEB_BUILD_NAME ?= $(DISTRIBUTION)-$(DEB_BUILD_ARCH)

QGIS_MAJOR=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_MAJOR "\([0-9]*\)")/\1/p' CMakeLists.txt)
QGIS_MINOR=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_MINOR "\([0-9]*\)")/\1/p' CMakeLists.txt)
QGIS_PATCH=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_PATCH "\([0-9]*\)")/\1/p' CMakeLists.txt)
QGIS_MAJOR=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_MAJOR "\([0-9]*\)")/\1/ip' CMakeLists.txt)
QGIS_MINOR=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_MINOR "\([0-9]*\)")/\1/ip' CMakeLists.txt)
QGIS_PATCH=$(shell sed -ne 's/SET(CPACK_PACKAGE_VERSION_PATCH "\([0-9]*\)")/\1/ip' CMakeLists.txt)
QGIS_ABI=$(QGIS_MAJOR).$(QGIS_MINOR).$(QGIS_PATCH)
GRASS=grass$(subst .,,$(shell pkg-config --modversion grass|cut -d. -f1,2))
GRASSVER=$(subst .,,$(shell pkg-config --modversion grass|cut -d. -f1))
@@ -284,13 +284,13 @@ sub getDeps {

open F, "../../CMakeLists.txt";
while(<F>) {
if(/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/) {
if(/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/i) {
$major = $1;
} elsif(/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/) {
} elsif(/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/i) {
$minor = $1;
} elsif(/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/) {
} elsif(/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/i) {
$patch = $1;
} elsif(/SET\(RELEASE_NAME "(.+)"\)/) {
} elsif(/SET\(RELEASE_NAME "(.+)"\)/i) {
$releasename = $1 unless defined $releasename;
}
}
@@ -115,11 +115,11 @@ else
fi

# Get the version string
major=$(grep -e 'SET(CPACK_PACKAGE_VERSION_MAJOR' ../CMakeLists.txt |
major=$(grep -ie 'SET(CPACK_PACKAGE_VERSION_MAJOR' ../CMakeLists.txt |
sed -r 's/.*\"([0-9]+)\".*/\1/g')
minor=$(grep -e 'SET(CPACK_PACKAGE_VERSION_MINOR' ../CMakeLists.txt |
minor=$(grep -ie 'SET(CPACK_PACKAGE_VERSION_MINOR' ../CMakeLists.txt |
sed -r 's/.*\"([0-9]+)\".*/\1/g')
patch=$(grep -e 'SET(CPACK_PACKAGE_VERSION_PATCH' ../CMakeLists.txt |
patch=$(grep -ie 'SET(CPACK_PACKAGE_VERSION_PATCH' ../CMakeLists.txt |
sed -r 's/.*\"([0-9]+)\".*/\1/g')

version=$major.$minor.$patch
@@ -28,10 +28,10 @@ ($$$$)
open I, "CMakeLists.txt.orig";
open O, ">CMakeLists.txt" or die "cannot create CMakeLists.txt: $!";
while(<I>) {
s/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/SET(CPACK_PACKAGE_VERSION_MAJOR "$major")/;
s/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/SET(CPACK_PACKAGE_VERSION_MINOR "$minor")/;
s/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/SET(CPACK_PACKAGE_VERSION_PATCH "$patch")/;
s/SET\(RELEASE_NAME "(.+)"\)/SET(RELEASE_NAME "$release")/;
s/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/set(CPACK_PACKAGE_VERSION_MAJOR "$major")/i;
s/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/set(CPACK_PACKAGE_VERSION_MINOR "$minor")/i;
s/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/set(CPACK_PACKAGE_VERSION_PATCH "$patch")/i;
s/SET\(RELEASE_NAME "(.+)"\)/set(RELEASE_NAME "$release")/i;
print O;
}
close O;
@@ -86,13 +86,13 @@ ($$)
my $releasename;
open F, "CMakeLists.txt";
while(<F>) {
if(/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/) {
if(/SET\(CPACK_PACKAGE_VERSION_MAJOR "(\d+)"\)/i) {
$major = $1;
} elsif(/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/) {
} elsif(/SET\(CPACK_PACKAGE_VERSION_MINOR "(\d+)"\)/i) {
$minor = $1;
} elsif(/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/) {
} elsif(/SET\(CPACK_PACKAGE_VERSION_PATCH "(\d+)"\)/i) {
$patch = $1;
} elsif(/SET\(RELEASE_NAME \"(.*)\"\)/) {
} elsif(/SET\(RELEASE_NAME \"(.*)\"\)/i) {
$releasename = $1;
}
}
@@ -210,8 +210,8 @@
open I, "i18n/CMakeLists.txt.temp";
open O, ">i18n/CMakeLists.txt";
while(<I>) {
if( /^SET\(TS_FILES / || /^FILE \(GLOB TS_FILES \*\.ts\)/ ) {
print O "SET(TS_FILES " . join( " ", map { "qgis_$_\.ts"; } @ts ) . ")\n";
if( /^SET\(TS_FILES /i ) {
print O "set(TS_FILES " . join( " ", map { "qgis_$_\.ts"; } @ts ) . ")\n";
} else {
print O;
}

0 comments on commit b5e9df9

Please sign in to comment.
You can’t perform that action at this time.