Skip to content

Commit

Permalink
Save the version in VERSION.txt instead of VERSION
Browse files Browse the repository at this point in the history
Fixes #6558
  • Loading branch information
slouken committed Nov 21, 2022
1 parent 802c624 commit 8ae46a4
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ build
gen
Build
buildbot
/VERSION
/VERSION.txt

*.so
*.so.*
Expand Down
2 changes: 1 addition & 1 deletion Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ LOCAL_MODULE := SDL2

LOCAL_C_INCLUDES := $(LOCAL_PATH)/include

LOCAL_EXPORT_C_INCLUDES := $(LOCAL_C_INCLUDES)
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_C_INCLUDES)/include

LOCAL_SRC_FILES := \
$(subst $(LOCAL_PATH)/,, \
Expand Down
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2960,8 +2960,8 @@ set(EXTRA_CFLAGS ${_EXTRA_CFLAGS})

# Compat helpers for the configuration files

if(EXISTS "${PROJECT_SOURCE_DIR}/VERSION")
file(READ "${PROJECT_SOURCE_DIR}/VERSION" SDL_SOURCE_VERSION)
if(EXISTS "${PROJECT_SOURCE_DIR}/VERSION.txt")
file(READ "${PROJECT_SOURCE_DIR}/VERSION.txt" SDL_SOURCE_VERSION)
string(STRIP "${SDL_SOURCE_VERSION}" SDL_SOURCE_VERSION)
endif()

Expand Down
4 changes: 2 additions & 2 deletions build-scripts/showrev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
SDL_ROOT=$(dirname $0)/..
cd $SDL_ROOT

if [ -e ./VERSION ]; then
cat ./VERSION
if [ -e ./VERSION.txt ]; then
cat ./VERSION.txt
exit 0
fi

Expand Down
2 changes: 1 addition & 1 deletion build-scripts/updaterev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ done
rev=`sh showrev.sh 2>/dev/null`
if [ "$rev" != "" ]; then
if [ -n "$dist" ]; then
echo "$rev" > "$outdir/VERSION"
echo "$rev" > "$outdir/VERSION.txt"
fi
echo "/* Generated by updaterev.sh, do not edit */" >"$header.new"
if [ -n "$vendor" ]; then
Expand Down

0 comments on commit 8ae46a4

Please sign in to comment.