From 7e2f1fba6c237fd6468196c4fd6e4f59ef36d1c1 Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 07:46:43 -0400 Subject: [PATCH 01/10] [ci] Test GCC13 potential fixes get more output update runner images mariadb packages brt regex strings str --- .github/workflows/build.yml | 18 +++++------ tools/ci/check_lua_binding_usage.py | 2 +- tools/ci/lua_stylecheck.py | 46 ++++++++++++++--------------- 3 files changed, 33 insertions(+), 33 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 22f71418a98..74485353eae 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,7 +17,7 @@ concurrency: jobs: Sanity_Checks: - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v3 with: @@ -25,8 +25,8 @@ jobs: - name: Install Dependencies run: | sudo apt-get update - sudo apt-get install -y software-properties-common cppcheck luajit-5.1-dev luarocks mariadb-server-10.6 mariadb-client-10.6 libmariadb-dev-compat binutils-dev - pip install -r tools/requirements.txt + sudo apt-get install -y software-properties-common cppcheck luajit-5.1-dev luarocks mariadb-server-core mariadb-server mariadb-client libmariadb-dev-compat binutils-dev + pip install --break-system-packages -r tools/requirements.txt luarocks install luacheck --local npm install -g diff-so-fancy - id: changed-files @@ -183,7 +183,7 @@ jobs: Linux_Clang15_64bit: needs: Sanity_Checks - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v3 with: @@ -218,12 +218,12 @@ jobs: Linux_ClangTidy15_64bit: needs: Sanity_Checks - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: # workaround for broken clang on ubuntu runner until fixed: https://github.com/actions/runner-images/issues/8659 - uses: claywar/workaround8649@4892524a133793c85e25513fae79fc968e63877c with: - os: ubuntu-22.04 + os: ubuntu-24.04 - uses: actions/checkout@v3 with: fetch-depth: 1 @@ -253,7 +253,7 @@ jobs: Linux_GCC13_64bit: needs: Sanity_Checks - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v3 with: @@ -363,7 +363,7 @@ jobs: cmake --build build -j4 Full_Startup_Checks_Linux: - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 needs: Linux_Clang15_64bit services: mysql: @@ -542,7 +542,7 @@ jobs: fi MultiInstance_Startup_Checks_Linux: - runs-on: ubuntu-22.04 + runs-on: ubuntu-24.04 needs: Linux_Clang15_64bit services: mysql: diff --git a/tools/ci/check_lua_binding_usage.py b/tools/ci/check_lua_binding_usage.py index 445df405679..71e3b235505 100644 --- a/tools/ci/check_lua_binding_usage.py +++ b/tools/ci/check_lua_binding_usage.py @@ -130,7 +130,7 @@ def main(): line = line.replace("\n", "") - for match in re.finditer('(?<=:)[^\(\/\\\: "]*', line): + for match in re.finditer(r'(?<=:)[^\(\/\\\: "]*', line): if ( len(match.group()) > 1 and match.group() not in function_names diff --git a/tools/ci/lua_stylecheck.py b/tools/ci/lua_stylecheck.py index 2cccacb4853..c2175fff8c1 100644 --- a/tools/ci/lua_stylecheck.py +++ b/tools/ci/lua_stylecheck.py @@ -118,19 +118,19 @@ def check_table_formatting(self, line): # [ ]{0,} : Any number of spaces # \n : newline character - for _ in re.finditer("[ ]{0,}=[ ]{0,}\{[ ]{0,}\n", line): + for _ in re.finditer(r"[ ]{0,}=[ ]{0,}\{[ ]{0,}\n", line): self.error("Incorrectly defined table") # \{ : Opening curly brace # [^ \n\}] : Match single characters in list: NOT space or NOT newline or NOT closing curly brace - for _ in re.finditer("\{[^ \n\}]", line): + for _ in re.finditer(r"\{[^ \n\}]", line): self.error("Table opened without an appropriate following space or newline") # [^ \n\{] : Match single characters in list: NOT space or NOT newline or NOT opening curly brace # \} : Closing curly brace - for _ in re.finditer("[^ \n\{]\}", line): + for _ in re.finditer(r"[^ \n\{]\}", line): self.error("Table closed without an appropriate preceding space or newline") def check_parameter_padding(self, line): @@ -142,7 +142,7 @@ def check_parameter_padding(self, line): """ # ,[^ \n] : Any comma that does not have space or newline following - for _ in re.finditer(",[^ \n]", line): + for _ in re.finditer(r",[^ \n]", line): self.error("Multiple parameters used without an appropriate following space or newline") def check_conditional_padding(self, line): @@ -150,7 +150,7 @@ def check_conditional_padding(self, line): # lstrip current line to prevent false-positives from indentation code_line = line.lstrip() - if re.search("\s{2,}(and|or)(\s{1,}|$)|\s{1,}(and|or)\s{2,}", code_line): + if re.search(r"\s{2,}(and|or)(\s{1,}|$)|\s{1,}(and|or)\s{2,}", code_line): self.error("Multiple spaces detected around logical operator.") def check_semicolon(self, line): @@ -160,12 +160,12 @@ def check_semicolon(self, line): """ # Ignore strings in line - quote_regex = regex.compile("\"(([^\"\"]+)|(?R))*+\"|\'(([^\'\']+)|(?R))*+\'", re.S) + quote_regex = regex.compile(r"\"(([^\"\"]+)|(?R))*+\"|\'(([^\'\']+)|(?R))*+\'", re.S) removed_quote_str = regex.sub(quote_regex, "", line) # ; : Any line that contains a semicolon. - for _ in re.finditer(";", removed_quote_str): + for _ in re.finditer(r";", removed_quote_str): self.error("Semicolon detected in line.") def check_variable_names(self, line): @@ -178,7 +178,7 @@ def check_variable_names(self, line): # [^(ID)]) : A token that is NOT 'ID' # (?=[A-Z]) : A token that starts with a capital letter - for match in re.finditer("local (?=[^(ID)])(?=[A-Z]){1,}", line): + for match in re.finditer(r"local (?=[^(ID)])(?=[A-Z]){1,}", line): self.error("Capitalised local name") if "local " in line and " =" in line: @@ -206,14 +206,14 @@ def check_operator_padding(self, line): """ # [^ =~\<\>][\=\+\*\~\/\>\<]|[\=\+\*\/\>\<][^ =\n] : Require space before and after >, <, >=, <=, ==, +, *, ~=, / operators or comparators - for _ in re.finditer("[^ =~\<\>][\=\+\*\~\/\>\<]|[\=\+\*\/\>\<][^ =\n]", line): + for _ in re.finditer(r"[^ =~\<\>][\=\+\*\~\/\>\<]|[\=\+\*\/\>\<][^ =\n]", line): self.error("Operator or comparator without padding detected at end of line") # For now, ignore all content in single-line tables to allow for formatting stripped_line = line.lstrip() - brace_regex = regex.compile("\{(([^\}\{]+)|(?R))*+\}", re.S) + brace_regex = regex.compile(r"\{(([^\}\{]+)|(?R))*+\}", re.S) stripped_line = regex.sub(brace_regex, "", stripped_line) - for _ in re.finditer("\s{2,}(>=|<=|==|~=|\+|\*|%|>|<|\^)|(>=|<=|==|~=|\+|\*|%|>|<|\^)\s{2,}", stripped_line): + for _ in re.finditer(r"\s{2,}(>=|<=|==|~=|\+|\*|%|>|<|\^)|(>=|<=|==|~=|\+|\*|%|>|<|\^)\s{2,}", stripped_line): self.error("Excessive padding detected around operator or comparator.") def check_parentheses_padding(self, line): @@ -223,7 +223,7 @@ def check_parentheses_padding(self, line): See: https://github.com/LandSandBoat/server/wiki/Development-Guide#lua-no-excess-whitespace """ - if len(re.findall("\([ ]| [\)]", line)) > 0: + if len(re.findall(r"\([ ]| [\)]", line)) > 0: if not line.lstrip(' ')[0] == '(' and not line.lstrip(' ')[0] == ')': # Ignore large blocks ending or opening self.error("No excess whitespace inside of parentheses or solely for alignment.") @@ -283,7 +283,7 @@ def check_no_function_decl_padding(self, line): See: TBD """ - if re.search("function\s{1,}\(", line): + if re.search(r"function\s{1,}\(", line): self.error("Padding detected between function and opening parenthesis") def check_multiline_condition_format(self, line): @@ -293,7 +293,7 @@ def check_multiline_condition_format(self, line): See: https://github.com/LandSandBoat/server/wiki/Development-Guide#lua-formatting-conditional-blocks """ - stripped_line = re.sub("\".*?\"|'.*?'", "", line) # Ignore data in quotes + stripped_line = re.sub(r"\".*?\"|'.*?'", "", line) # Ignore data in quotes if contains_word('if')(stripped_line) or contains_word('elseif')(stripped_line): condition_start = stripped_line.replace('elseif','').replace('if','').strip() if not 'then' in condition_start and condition_start != '': @@ -367,12 +367,12 @@ def run_style_check(self): continue comment_header = line.rstrip("\n") - if re.search("^-+$", comment_header) and len(comment_header) > 2 and len(comment_header) != 35: + if re.search(r"^-+$", comment_header) and len(comment_header) > 2 and len(comment_header) != 35: # For now, ignore empty comments with only `--` self.error("Standard comment block lines of '-' should be 35 characters.") # Remove in-line comments - code_line = re.sub("(?=--)(.*?)(?=\r\n|\n)", "", line).rstrip() + code_line = re.sub(r"(?=--)(.*?)(?=\r\n|\n)", "", line).rstrip() # Before replacing strings, see if we're only using single quotes and check requires if re.search(r"\"[^\"']*\"(?=(?:[^']*'[^']*')*[^']*$)", code_line): @@ -383,8 +383,8 @@ def run_style_check(self): code_line = code_line.replace("\\'", '') code_line = code_line.replace('\\"', '') - code_line = re.sub('\"([^\"]*?)\"', "strVal", code_line) - code_line = re.sub("\'([^\"]*?)\'", "strVal", code_line) + code_line = re.sub(r'\"([^\"]*?)\"', "strVal", code_line) + code_line = re.sub(r"\'([^\"]*?)\'", "strVal", code_line) # Checks that apply to all lines self.check_table_formatting(code_line) @@ -406,10 +406,10 @@ def run_style_check(self): # Keep track of ID variable assignments and if they are referenced. # TODO: Track each unique variable, and expand this to potentially something # more generic for other tests. - if re.search("ID[ ]+=[ ]+zones\[", code_line): + if re.search(r"ID[ ]+=[ ]+zones\[", code_line): uses_id = True - if uses_id == True and re.search("ID\.", code_line): + if uses_id == True and re.search(r"ID\.", code_line): has_id_ref = True # Multiline conditionals should not have data in if, elseif, or then @@ -441,16 +441,16 @@ def run_style_check(self): if contains_word('then')(code_line): condition_str = full_condition.replace('elseif','').replace('if','').replace('then','').strip() - paren_regex = regex.compile("\((([^\)\(]+)|(?R))*+\)", re.S) + paren_regex = regex.compile(r"\((([^\)\(]+)|(?R))*+\)", re.S) removed_paren_str = regex.sub(paren_regex, "", condition_str) if removed_paren_str == "": self.error("Outer parentheses should be removed in condition") - if len(re.findall("== true|== false|~= true|~= false", condition_str)) > 0: + if len(re.findall(r"== true|== false|~= true|~= false", condition_str)) > 0: self.error("Boolean with explicit value check") - if not in_condition and len(re.findall(" and | or ", condition_str)) > 0 and len(condition_str) > 72: + if not in_condition and len(re.findall(r" and | or ", condition_str)) > 0 and len(condition_str) > 72: self.error("Multiline conditional format required") in_condition = False From 69a95eaba662738a4d4b8b6a10787efdeceec55f Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 08:45:19 -0400 Subject: [PATCH 02/10] update python3 path for pip little more testing more python3 path changes test test bad venv path --- .github/workflows/build.yml | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 74485353eae..d2feafafa32 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,8 +25,14 @@ jobs: - name: Install Dependencies run: | sudo apt-get update - sudo apt-get install -y software-properties-common cppcheck luajit-5.1-dev luarocks mariadb-server-core mariadb-server mariadb-client libmariadb-dev-compat binutils-dev - pip install --break-system-packages -r tools/requirements.txt + sudo apt-get install -y software-properties-common cppcheck luajit-5.1-dev luarocks mariadb-server-core mariadb-server mariadb-client libmariadb-dev-compat binutils-dev clang-format + + mkdir .venv + python3 -m venv .venv + source .venv/bin/activate + which python + + .venv/bin/pip install -r tools/requirements.txt luarocks install luacheck --local npm install -g diff-so-fancy - id: changed-files @@ -88,15 +94,15 @@ jobs: exit 1 fi exit 0 - - name: CPP Formatting Checks (clang-format-15) + - name: CPP Formatting Checks (clang-format-18) if: always() run: | - clang-format-15 -version + clang-format-18 -version touch cpp_formatting_checks.txt for changed_file in ${{ steps.changed-files.outputs.all }}; do if [[ -f $changed_file ]]; then if [[ $changed_file == *.cpp || $changed_file == *.h ]]; then - clang-format-15 -style=file -i ${changed_file} + clang-format-18 -style=file -i ${changed_file} fi fi done @@ -125,7 +131,8 @@ jobs: if: always() run: | touch lua_checks.txt - python3 tools/ci/lua_stylecheck.py test >> lua_checks.txt + pwd + .venv/bin/python3 tools/ci/lua_stylecheck.py test >> lua_checks.txt for changed_file in ${{ steps.changed-files.outputs.all }}; do if [[ -f $changed_file ]]; then @@ -135,7 +142,7 @@ jobs: fi done - python3 tools/ci/check_lua_binding_usage.py >> lua_checks.txt + .venv/bin/python3 tools/ci/check_lua_binding_usage.py >> lua_checks.txt cat lua_checks.txt if [ -s lua_checks.txt ] @@ -155,7 +162,7 @@ jobs: fi done - python3 tools/price_checker.py >> sql_checks.txt + .venv/bin/python3 tools/price_checker.py >> sql_checks.txt cat sql_checks.txt if [ -s sql_checks.txt ] @@ -327,7 +334,7 @@ jobs: - name: Enable Modules shell: bash run: | - python3 << EOF + .venv/bin/python3 << EOF with open("modules/init.txt", "w") as f: f.write("custom\n") f.write("era\n") @@ -403,7 +410,7 @@ jobs: - name: Enable Modules shell: bash run: | - python3 << EOF + .venv/bin/python3 << EOF with open("modules/init.txt", "w") as f: f.write("custom\n") f.write("era\n") @@ -492,7 +499,7 @@ jobs: VALUES(1, 'GodMode', 1);" printf "\nRunning HeadlessXI for 60 seconds\n" - python3 << EOF + .venv/bin/python3 << EOF import time try: from tools.headlessxi.hxiclient import HXIClient @@ -659,4 +666,4 @@ jobs: - name: Startup checks shell: bash run: | - python3 ./tools/ci/startup_checks.py + .venv/bin/python3 ./tools/ci/startup_checks.py From 779f4fc46c13feb686bb9ec886d27324bf140ae4 Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 08:49:12 -0400 Subject: [PATCH 03/10] git formatting check --- tools/ci/git.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/ci/git.sh b/tools/ci/git.sh index dee9f8afdf3..dcde1c16063 100644 --- a/tools/ci/git.sh +++ b/tools/ci/git.sh @@ -78,7 +78,7 @@ for hash, lines in get_commit_messages().items(): # [^ ]*\. : Any number characters that are NOT a space, ending in a period character. # [a-z]{1,3} : 1-3 entries of characters a-z. This is looking for file extensions. # $ : End of string. - for match in re.finditer("^update [^ ]*\.[a-z]{1,3}$", line.lower()): + for match in re.finditer(r"^update [^ ]*\.[a-z]{1,3}$", line.lower()): print_error(hash, lines, line, "Detected automatic commit message (Example: \"Update filename.ext\").\nPlease " "provide a more detailed summary of your changes.") From 82ee6f5aae1a70aa5d6c6bc3f0cf6cd4165036cd Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 08:50:36 -0400 Subject: [PATCH 04/10] update clang version --- .github/workflows/build.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d2feafafa32..13d5c73cd74 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -206,8 +206,8 @@ jobs: # key: ${{ runner.os }}-clang - name: Configure CMake run: | - export CC=/usr/bin/clang-15 - export CXX=/usr/bin/clang++-15 + export CC=/usr/bin/clang-18 + export CXX=/usr/bin/clang++-18 mkdir -p build cmake -S . -B build - name: Build @@ -245,8 +245,8 @@ jobs: # key: ${{ runner.os }}-clang - name: Configure CMake run: | - export CC=/usr/bin/clang-15 - export CXX=/usr/bin/clang++-15 + export CC=/usr/bin/clang-18 + export CXX=/usr/bin/clang++-18 mkdir -p build cmake -S . -B build -DENABLE_CLANG_TIDY=ON - name: Build From 98efaf4ba11fbfd3cce6dc8fdc1a665c3c3031fe Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 08:51:44 -0400 Subject: [PATCH 05/10] Fix incorrect path for windows checks --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 13d5c73cd74..37fe78d94aa 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -410,7 +410,7 @@ jobs: - name: Enable Modules shell: bash run: | - .venv/bin/python3 << EOF + python3 << EOF with open("modules/init.txt", "w") as f: f.write("custom\n") f.write("era\n") From 8e108ebcb7990d0f1bcd36f58fd8ee774127bdaf Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 08:56:06 -0400 Subject: [PATCH 06/10] Update clang titles, fix incorrect path --- .github/workflows/build.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 37fe78d94aa..6569ab57c05 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -188,7 +188,7 @@ jobs: fi exit 0 - Linux_Clang15_64bit: + Linux_Clang18_64bit: needs: Sanity_Checks runs-on: ubuntu-24.04 steps: @@ -223,7 +223,7 @@ jobs: xi_search xi_world - Linux_ClangTidy15_64bit: + Linux_ClangTidy18_64bit: needs: Sanity_Checks runs-on: ubuntu-24.04 steps: @@ -334,7 +334,7 @@ jobs: - name: Enable Modules shell: bash run: | - .venv/bin/python3 << EOF + python3 << EOF with open("modules/init.txt", "w") as f: f.write("custom\n") f.write("era\n") @@ -371,7 +371,7 @@ jobs: Full_Startup_Checks_Linux: runs-on: ubuntu-24.04 - needs: Linux_Clang15_64bit + needs: Linux_Clang18_64bit services: mysql: image: mariadb:10.6 @@ -550,7 +550,7 @@ jobs: MultiInstance_Startup_Checks_Linux: runs-on: ubuntu-24.04 - needs: Linux_Clang15_64bit + needs: Linux_Clang18_64bit services: mysql: image: mariadb:10.6 From 088ab4aab6579ef3719e46d38298bd15f39798da Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 09:11:56 -0400 Subject: [PATCH 07/10] More fixes for paths, comments, ignore clang error --- .clang-tidy | 3 +++ .github/workflows/build.yml | 2 +- tools/run_clang_format.bat | 2 +- tools/run_clang_format.sh | 4 ++-- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.clang-tidy b/.clang-tidy index 8710899756c..75706f40a6c 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -18,6 +18,9 @@ Checks: > modernize-use-override, performance-*, + # TODO + -nan-infinity-disabled + # TODO: Enable these # concurrency-mt-unsafe, # cppcoreguidelines-prefer-member-initializer, diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6569ab57c05..5d5c062725a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -666,4 +666,4 @@ jobs: - name: Startup checks shell: bash run: | - .venv/bin/python3 ./tools/ci/startup_checks.py + python3 ./tools/ci/startup_checks.py diff --git a/tools/run_clang_format.bat b/tools/run_clang_format.bat index 923fe6e29c1..2d7c3274a98 100644 --- a/tools/run_clang_format.bat +++ b/tools/run_clang_format.bat @@ -1,5 +1,5 @@ REM Run from repo root -REM Uses clang-format-15 +REM Uses clang-format-18 for /r %cd%\src\ %%f in (*.cpp) do clang-format -style=file -i %%f for /r %cd%\src\ %%f in (*.h) do clang-format -style=file -i %%f diff --git a/tools/run_clang_format.sh b/tools/run_clang_format.sh index eabcab5babe..91facdff77e 100644 --- a/tools/run_clang_format.sh +++ b/tools/run_clang_format.sh @@ -1,3 +1,3 @@ # Run from repo root -for f in $(find src/ -name '*.h' -or -name '*.cpp'); do clang-format-15 -style=file -i $f; done -for f in $(find modules/ -name '*.h' -or -name '*.cpp'); do clang-format-15 -style=file -i $f; done +for f in $(find src/ -name '*.h' -or -name '*.cpp'); do clang-format-18 -style=file -i $f; done +for f in $(find modules/ -name '*.h' -or -name '*.cpp'); do clang-format-18 -style=file -i $f; done From d5ca218016662498f904a87e6d878a75e3c7bb7d Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 09:29:31 -0400 Subject: [PATCH 08/10] Update to gcc-14, add -Wno-nan-infinity-disabled --- .clang-tidy | 3 --- .github/workflows/build.yml | 6 +++--- cmake/CompilerWarnings.cmake | 1 + 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.clang-tidy b/.clang-tidy index 75706f40a6c..8710899756c 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -18,9 +18,6 @@ Checks: > modernize-use-override, performance-*, - # TODO - -nan-infinity-disabled - # TODO: Enable these # concurrency-mt-unsafe, # cppcoreguidelines-prefer-member-initializer, diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5d5c062725a..e4d06a9a019 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -258,7 +258,7 @@ jobs: exit 1 fi - Linux_GCC13_64bit: + Linux_GCC14_64bit: needs: Sanity_Checks runs-on: ubuntu-24.04 steps: @@ -276,8 +276,8 @@ jobs: # key: ${{ runner.os }}-gcc - name: Configure CMake run: | - export CC=/usr/bin/gcc-13 - export CXX=/usr/bin/g++-13 + export CC=/usr/bin/gcc-14 + export CXX=/usr/bin/g++-14 mkdir -p build CFLAGS=-m64 CXXFLAGS=-m64 LDFLAGS=-m64 cmake -S . -B build - name: Build diff --git a/cmake/CompilerWarnings.cmake b/cmake/CompilerWarnings.cmake index bd232685d24..992a559910c 100644 --- a/cmake/CompilerWarnings.cmake +++ b/cmake/CompilerWarnings.cmake @@ -63,6 +63,7 @@ function(set_project_warnings project_name) -Wno-unused-parameter # warn on unused function parameters -Wno-missing-field-initializers -Wno-sign-compare + -Wno-nan-infinity-disabled # TODO: This is good, but it's Clang only # -Wunused-private-field # warn on unused private fields From 1a5e29e5f2065d68c6b50d6f423e4408ceb03211 Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 10:08:08 -0400 Subject: [PATCH 09/10] Fix dependencies for startup checks d --- .github/workflows/build.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e4d06a9a019..3640a25c508 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -360,7 +360,7 @@ jobs: fetch-depth: 1 - name: Install Dependencies (Brew) run: | - brew install mariadb zeromq zmq luajit + brew install mariadb zeromq zmq luajit llvm@18 - name: Configure CMake run: | mkdir -p build @@ -392,8 +392,14 @@ jobs: - name: Install Dependencies run: | sudo apt-get update - sudo apt-get install -y software-properties-common cmake mariadb-client-10.6 libmariadb-dev-compat libluajit-5.1-dev libzmq3-dev zlib1g-dev libssl-dev luarocks binutils-dev - pip install bcrypt + sudo apt-get install -y software-properties-common cmake mariadb-server-core mariadb-server mariadb-client libmariadb-dev-compat libluajit-5.1-dev libzmq3-dev zlib1g-dev libssl-dev luarocks binutils-dev + + mkdir .venv + python3 -m venv .venv + source .venv/bin/activate + which python + + .venv/bin/pip install bcrypt - name: Verify MySQL connection from container run: | mysql -h 127.0.0.1 -uroot -proot -e "SHOW DATABASES" @@ -571,7 +577,7 @@ jobs: - name: Install Dependencies run: | sudo apt-get update - sudo apt-get install -y software-properties-common cmake mariadb-client-10.6 libmariadb-dev-compat libluajit-5.1-dev libzmq3-dev zlib1g-dev libssl-dev luarocks binutils-dev + sudo apt-get install -y software-properties-common cmake mariadb-server-core mariadb-server mariadb-client libmariadb-dev-compat libluajit-5.1-dev libzmq3-dev zlib1g-dev libssl-dev luarocks binutils-dev - name: Verify MySQL connection from container run: | mysql -h 127.0.0.1 -uroot -proot -e "SHOW DATABASES" From b957a2f9f865897dbe19f773cb83e08068c70d35 Mon Sep 17 00:00:00 2001 From: claywar Date: Thu, 16 May 2024 12:14:58 -0400 Subject: [PATCH 10/10] Add ldflags for macOS build set cxx macos mac more mac more mac mac again mac tonight test again even more --- .github/workflows/build.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3640a25c508..d3c00ff86db 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -353,14 +353,15 @@ jobs: MacOS_64bit: needs: Sanity_Checks # https://github.com/actions/runner-images/blob/main/images/macos/macos-13-Readme.md - runs-on: macos-13 + runs-on: macos-14 steps: - uses: actions/checkout@v3 with: fetch-depth: 1 - name: Install Dependencies (Brew) run: | - brew install mariadb zeromq zmq luajit llvm@18 + brew update + brew install mariadb zeromq zmq luajit llvm - name: Configure CMake run: | mkdir -p build