Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ cmake_minimum_required(VERSION 3.16)
set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX "${CMAKE_CURRENT_SOURCE_DIR}/cmake/cxx_compiler_flags_overrides.cmake")

# Read version from VERSION.txt file
file(READ "${CMAKE_CURRENT_SOURCE_DIR}/VERSION.txt" Z3_VERSION_FROM_FILE)
file(READ "${CMAKE_CURRENT_SOURCE_DIR}/scripts/VERSION.txt" Z3_VERSION_FROM_FILE)
string(STRIP "${Z3_VERSION_FROM_FILE}" Z3_VERSION_FROM_FILE)

project(Z3 VERSION ${Z3_VERSION_FROM_FILE} LANGUAGES CXX)
Expand Down
2 changes: 1 addition & 1 deletion MODULE.bazel
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module(
name = "z3",
version = "4.16.0", # TODO: Read from VERSION.txt - currently manual sync required
version = "4.15.4", # TODO: Read from VERSION.txt - currently manual sync required
bazel_compatibility = [">=7.0.0"],
)

Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion scripts/mk_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

def init_version():
# Read version from VERSION.txt file
version_file_path = os.path.join(os.path.dirname(os.path.dirname(__file__)), 'VERSION.txt')
version_file_path = os.path.join(os.path.dirname(__file__), 'VERSION.txt')
try:
with open(version_file_path, 'r') as f:
version_str = f.read().strip()
Expand Down
4 changes: 2 additions & 2 deletions scripts/nightly.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
variables:
# Version components read from VERSION.txt (updated manually when VERSION.txt changes)
Major: '4'
Minor: '16'
Patch: '0'
Minor: '15'
Patch: '4'
ReleaseVersion: $(Major).$(Minor).$(Patch)
AssemblyVersion: $(Major).$(Minor).$(Patch).$(Build.BuildId)
NightlyVersion: $(AssemblyVersion)-$(Build.buildId)
Expand Down
2 changes: 1 addition & 1 deletion scripts/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
trigger: none

variables:
ReleaseVersion: '4.16.0' # TODO: Auto-read from VERSION.txt when Azure DevOps supports it better
ReleaseVersion: '4.15.4' # TODO: Auto-read from VERSION.txt when Azure DevOps supports it better

stages:

Expand Down
2 changes: 1 addition & 1 deletion scripts/update_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
def read_version():
"""Read version from VERSION.txt file."""
script_dir = os.path.dirname(os.path.abspath(__file__))
version_file = os.path.join(os.path.dirname(script_dir), 'VERSION.txt')
version_file = os.path.join(script_dir, 'VERSION.txt')

try:
with open(version_file, 'r') as f:
Expand Down
4 changes: 3 additions & 1 deletion src/api/python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,8 @@ def _z3_version():
if os.path.exists(d):
print(d, ": ", os.listdir(d))
fns = [os.path.join(d, 'VERSION.txt') for d in dirs]
# Also try the scripts directory
fns.extend([os.path.join(d, 'scripts', 'VERSION.txt') for d in dirs])
for fn in fns:
print("loading version file", fn, "exists", os.path.exists(fn))
if os.path.exists(fn):
Expand Down Expand Up @@ -254,7 +256,7 @@ def _copy_sources():

# shutil.copy(os.path.join(SRC_DIR_REPO, 'LICENSE.txt'), ROOT_DIR)
shutil.copy(os.path.join(SRC_DIR_REPO, 'LICENSE.txt'), SRC_DIR_LOCAL)
shutil.copy(os.path.join(SRC_DIR, 'VERSION.txt'), SRC_DIR_LOCAL)
shutil.copy(os.path.join(SRC_DIR, 'scripts', 'VERSION.txt'), SRC_DIR_LOCAL)
shutil.copy(os.path.join(SRC_DIR_REPO, 'z3.pc.cmake.in'), SRC_DIR_LOCAL)
shutil.copy(os.path.join(SRC_DIR_REPO, 'CMakeLists.txt'), SRC_DIR_LOCAL)
shutil.copytree(os.path.join(SRC_DIR_REPO, 'cmake'), os.path.join(SRC_DIR_LOCAL, 'cmake'))
Expand Down
Loading