From 8b8308c3544788179bc128f51b56d8d756fb1662 Mon Sep 17 00:00:00 2001 From: kaetemi Date: Fri, 17 Apr 2020 08:16:53 +0800 Subject: [PATCH 1/2] Allow setting patch version --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0df8279f1..54b133ac3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -54,8 +54,8 @@ ENDIF() CMAKE_MINIMUM_REQUIRED(VERSION 2.6) PROJECT(RyzomCore CXX C) SET(NL_VERSION_MAJOR 1) -SET(NL_VERSION_MINOR 0) -SET(NL_VERSION_PATCH 2) +SET(NL_VERSION_MINOR 1) +SET(NL_VERSION_PATCH 0 CACHE STRING "Patch version") SET(YEAR "2001-${CURRENT_YEAR}") SET(AUTHOR "Winch Gate and The Ryzom Core Community") From d0068265fb715cd96eab9ca8d8f3b0efe5e76448 Mon Sep 17 00:00:00 2001 From: kaetemi Date: Fri, 17 Apr 2020 06:11:56 +0800 Subject: [PATCH 2/2] Compare tag for creating bnp, since bnp get older timestamp reset if they match --- nel/tools/build_gamedata/d1_client_patch.py | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/nel/tools/build_gamedata/d1_client_patch.py b/nel/tools/build_gamedata/d1_client_patch.py index ea4cc742c..5237542f6 100755 --- a/nel/tools/build_gamedata/d1_client_patch.py +++ b/nel/tools/build_gamedata/d1_client_patch.py @@ -123,7 +123,9 @@ else: printLog(log, "") printLog(log, ">>> Make bnp <<<") targetPath = ClientPatchDirectory + "/bnp" + tagPath = ClientPatchDirectory + "/bnp_tag" mkPath(log, targetPath) + mkPath(log, tagPath) for category in InstallClientData: packExt = ".bnp" if (category["StreamedPackages"]): @@ -133,25 +135,32 @@ else: sourcePath = InstallDirectory + "/" + package[0] mkPath(log, sourcePath) targetBnp = targetPath + "/" + package[0] + packExt + tagBnp = tagPath + "/" + package[0] + packExt + ".tag" if (len(package[1]) > 0): targetBnp = targetPath + "/" + package[1][0] + tagBnp = tagPath + "/" + package[1][0] + ".tag" printLog(log, "TARGET " + package[1][0]) needUpdateBnp = 1 if (len(package) > 2): - needUpdateBnp = needUpdate(log, sourcePath + "/" + package[2], targetBnp) + needUpdateBnp = needUpdate(log, sourcePath + "/" + package[2], tagBnp) else: - needUpdateBnp = needUpdateDirNoSubdirFile(log, sourcePath, targetBnp) + needUpdateBnp = needUpdateDirNoSubdirFile(log, sourcePath, tagBnp) if (needUpdateBnp): + subRet = 0 + open(tagBnp, 'a').close() + os.utime(tagBnp, None) if (category["StreamedPackages"]): printLog(log, "SNP " + targetBnp) # cwDir = os.getcwd().replace("\\", "/") # toolDir = os.path.dirname(Lzma).replace("\\", "/") # os.chdir(toolDir) - subprocess.call([ SnpMake, "-p", sourcePath, targetBnp, ClientPatchDirectory + "/stream" ] + package[1][1:]) + subRet = subprocess.call([ SnpMake, "-p", sourcePath, targetBnp, ClientPatchDirectory + "/stream" ] + package[1][1:]) # os.chdir(cwDir) else: printLog(log, "BNP " + targetBnp) - subprocess.call([ BnpMake, "-p", sourcePath, "-o", targetBnp ] + package[1][1:]) + subRet = subprocess.call([ BnpMake, "-p", sourcePath, "-o", targetBnp ] + package[1][1:]) + if (subRet != 0): + os.remove(tagBnp) else: printLog(log, "SKIP " + targetBnp) printLog(log, "")