From f7f92578cddfbc3889d91d5a1b63e9079efbe603 Mon Sep 17 00:00:00 2001 From: Gerald Combs Date: Thu, 28 Apr 2016 17:55:46 -0700 Subject: make-version.pl: Preserve line endings. Make sure we replace a line using the same line endings. Change-Id: I73b07a773bc39b05ba7a73b3c3c984a73c545a48 Reviewed-on: https://code.wireshark.org/review/15157 Petri-Dish: Gerald Combs Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs --- make-version.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'make-version.pl') diff --git a/make-version.pl b/make-version.pl index f1fc8466a1..c392116596 100755 --- a/make-version.pl +++ b/make-version.pl @@ -421,8 +421,8 @@ sub update_cmakelists_txt $line = sprintf("set(PROJECT_MINOR_VERSION %d)$1", $version_pref{"version_minor"}); } elsif ($line =~ /^set *\( *PROJECT_PATCH_VERSION .*([\r\n]+)$/) { $line = sprintf("set(PROJECT_PATCH_VERSION %d)$1", $version_pref{"version_micro"}); - } elsif ($line =~ /^set *\( *PROJECT_VERSION_EXTENSION\b.*\) *$/) { - $line = sprintf("set(PROJECT_VERSION_EXTENSION \"%s\")\n", $cmake_package_string); + } elsif ($line =~ /^set *\( *PROJECT_VERSION_EXTENSION\b.*\) *([\r\n]+)$/) { + $line = sprintf("set(PROJECT_VERSION_EXTENSION \"%s\")$1", $cmake_package_string); } $contents .= $line } -- cgit v1.2.1