Skip to content

Commit 3063215

Browse files
committed
Use uppercase hexidecimal for version in library.
1 parent cc7dc51 commit 3063215

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

minexiii/validation/VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
201902281135
1+
201907011032

minexiii/validation/validate

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,13 @@ if [ "${core_lib}" == "" ]; then
143143
fail "No core library found. Please review library naming conventions."
144144
fi
145145

146+
# Some file systems are case-sensitive
147+
cbeff_version_raw="$(echo ${core_lib} | awk -F_ '{print $3}' | sed 's/\..*//')"
148+
if [ "${cbeff_version_raw}" != "$(tr '[:lower:]' '[:upper:]' <<< ${cbeff_version_raw})" ]; then
149+
correct="$(cut -f1 -d_ <<< ${core_lib})_$(cut -f2 -d_ <<< ${core_lib})_$(tr '[:lower:]' '[:upper:]' <<< ${cbeff_version_raw}).$(cut -f2 -d. <<< ${core_lib})"
150+
fail "Please use uppercase hexadecimal digits (\"ABCDEF\" instead of \"abcdef\") for the version in your library name. Please rebuild \"${core_lib}\" as \"${correct}.\""
151+
fi
152+
146153
# If SONAME is present, check that it is the same as the lib name
147154
file "${WD}"/${MINEX_LIB_DIR}/${core_lib} | grep shared > /dev/null
148155
if [ $? -eq 0 ]; then
@@ -154,7 +161,7 @@ if [ $? -eq 0 ]; then
154161
fi
155162
fi
156163
COMPANY=`echo ${core_lib} | awk -F_ '{print $2}'`
157-
CBEFF_VERSION=`echo ${core_lib} | awk -F_ '{print $3}' | sed 's/\..*//' | tr '[:lower:]' '[:upper:]'`
164+
CBEFF_VERSION=`echo ${core_lib} | awk -F_ '{print $3}' | sed 's/\..*//'`
158165
echo "($core_lib) [OKAY]"
159166

160167
# Check for configuration files

0 commit comments

Comments
 (0)