From d7e0e59dc830cd3f121cb0f7b183ef25c33ad5bd Mon Sep 17 00:00:00 2001 From: Gonzalo Diaz Date: Mon, 9 Dec 2024 23:23:36 -0300 Subject: [PATCH 1/4] [BUGFIX] .lcovrc updated to match lcov 2.2-1 (local homebrew version). --- .lcovrc | 507 ++++++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 436 insertions(+), 71 deletions(-) diff --git a/.lcovrc b/.lcovrc index 1b9cc29..feccaa4 100644 --- a/.lcovrc +++ b/.lcovrc @@ -1,108 +1,292 @@ -# Example LCOV configuration file -# -# External style sheet file -#genhtml_css_file = gcov.css -# Coverage rate limits for line coverage -genhtml_hi_limit = 80 -genhtml_med_limit = 50 +# /etc/lcovrc - system-wide defaults for LCOV +# +# To change settings for a single user, place a customized copy of this file +# at location ~/.lcovrc +# +# Note that this example script does not include all configuration options +# see 'man lcovrc(5) for a complete list and usage description. -# Coverage rate limits for function coverage -genhtml_function_hi_limit = 90 -genhtml_function_med_limit = 75 +# Specify an external style sheet file (same as --css-file option of genhtml) +#genhtml_css_file = gcov.css -# Width of overview image +# use 'dark' mode display (light foreground, dark background) instead of default +# same as 'genhtml --dark-mode ....' +#genhtml_dark_mode = 1 + +# Header text to use at top of each page +# Default is "LCOV - (differential )? coverage report" +#genhtml_header = Coverage report for my project + +# Footer text to use at the bottom of each page +# Default is LCOV tool version +#genhtml_footer = My footer text + +# Specify global coverage rate limits (in %) for classifying file entries +# HI: hi_limit <= rate <= 100 graph color: green +# MED: med_limit <= rate < hi_limit graph color: orange +# LO: 0 <= rate < med_limit graph color: red +genhtml_hi_limit = 90 +genhtml_med_limit = 75 + +# Specify line coverage rate limits (in %) for classifying file entries +# HI: ln_hi_limit <= rate <= 100 graph color: green +# MED: ln_med_limit <= rate < ln_hi_limit graph color: orange +# LO: 0 <= rate < ln_med_limit graph color: red +# genhtml_line_hi_limit = 90 +# genhtml_line_med_limit = 75 + +# Specify function coverage rate limits (in %) for classifying file entries +# HI: fn_hi_limit <= rate <= 100 graph color: green +# MED: fn_med_limit <= rate < fn_hi_limit graph color: orange +# LO: 0 <= rate < fn_med_limit graph color: red +# genhtml_function_hi_limit = 90 +# genhtml_function_med_limit = 75 + +# Specify branch coverage rate limits (in %) for classifying file entries +# HI: br_hi_limit <= rate <= 100 graph color: green +# MED: br_med_limit <= rate < br_hi_limit graph color: orange +# LO: 0 <= rate < br_med_limit graph color: red +# genhtml_branch_hi_limit = 90 +# genhtml_branch_med_limit = 75 + +# Ignore some errors during geninfo/lcov/genhtml processing - comma-separated +# string. Same as using "--ignore-errors a,b,c" command line option. +# See man pages for list of ignorable messages +#ignore_errors = empty,mismatch + +# Stop emitting message after this number have been printed +# 0 == no limit +max_message_count = 100 + +# If set, do not stop when an 'ignorable error' occurs - try to generate +# a result, however flawed. This is equivalent to the '--keep-going' +# command line switch. +# Default is 1: stop when error occurs +# See the man pages for more detail +#stop_on_error = 1 + +# If nonzero, treat warnings as error +# note that ignored messages will still appear as warnings +# Default is 0 +#treat_warning_as_error = 1 + +# If set to non-zero, only issue particluar warning once per file +# Default is 1 +#warn_once_per_file = 1 + +# extension associated with lcov trace files - glob match pattern +# used as argument to 'find' - to find coverage files contained in +# a directory argument +#info_file_pattern = *.info + +# List of file extensions which should be treated as RTL code (e.g., Verilog) +# Comma-separated list. Default is "v,vh,sv,vhd?" +#rtl_file_extensions = v,vh,sv,vhd? + +# list of file extensions which should be treated as C/C++ code +# (comma-separated list) +#c_file_extensions = h,c,i,C,H,I,cpp,hpp,icc,cc,hh,cxx,hxx + +# list of file extensions which should be treated as Java code +#java_file_extensions = java + +# list of file extensions which should be treated as perl code +#perl_file_extensions = pl,pm + +# list of file extensions which should be treated as python code +#python_file_extensions = py + +# maximum number of lines to look at, when filtering bogus branch expressions +#filter_lookahead = 5 + +# if nonzero, bitwise operators '|', '&', '~' indicate conditional expressions +#filter_bitwise_conditional = 1 + +# if nonzero, '--filter blank' is applied to blank lines, regardless +# of their hit count +#filter_blank_aggressive = 1 + +# Width of line coverage field in source code view +genhtml_line_field_width = 12 + +# Width of branch coverage field in source code view +genhtml_branch_field_width = 16 + +# Width of MC/DC coverage field in source code view +genhtml_mcdc_field_width = 16 + +# width of 'owner' field in source code view - default is 20 +#genhtml_owner_field_width = 20 + +# width of 'age' field in source code view - default is 5 +#genhtml_age_field_width = 5 + +# Width of overview image (used by --frames option of genhtml) genhtml_overview_width = 80 -# Resolution of overview navigation +# Resolution of overview navigation: this number specifies the maximum +# difference in lines between the position a user selected from the overview +# and the position the source code window is scrolled to (used by --frames +# option of genhtml) genhtml_nav_resolution = 4 -# Offset for source code navigation +# Clicking a line in the overview image should show the source code view at +# a position a bit further up so that the requested line is not the first +# line in the window. This number specifies that offset in lines (used by +# --frames option of genhtml) genhtml_nav_offset = 10 -# Do not remove unused test descriptions if non-zero +# Do not remove unused test descriptions if non-zero (same as +# --keep-descriptions option of genhtml) genhtml_keep_descriptions = 0 -# Do not remove prefix from directory names if non-zero +# Do not remove prefix from directory names if non-zero (same as --no-prefix +# option of genhtml) genhtml_no_prefix = 0 -# Do not create source code view if non-zero +# Do not create source code view if non-zero (same as --no-source option of +# genhtml) genhtml_no_source = 0 -# Specify size of tabs +# Replace tabs with number of spaces in source view (same as --num-spaces +# option of genhtml) genhtml_num_spaces = 8 -# Highlight lines with converted-only data if non-zero -genhtml_highlight = 0 - -# Include color legend in HTML output if non-zero +# Include color legend in HTML output if non-zero (same as --legend option of +# genhtml) genhtml_legend = 0 -# Include HTML file at start of HTML output -#genhtml_html_prolog = prolog.html +# Use FILE as HTML prolog for generated pages (same as --html-prolog option of +# genhtml) +#genhtml_html_prolog = FILE -# Include HTML file at end of HTML output -#genhtml_html_epilog = epilog.html +# Use FILE as HTML epilog for generated pages (same as --html-epilog option of +# genhtml) +#genhtml_html_epilog = FILE -# Use custom HTML file extension +# Use custom filename extension for pages (same as --html-extension option of +# genhtml) #genhtml_html_extension = html # Compress all generated html files with gzip. #genhtml_html_gzip = 1 -# Include sorted overview pages +# Include sorted overview pages (can be disabled by the --no-sort option of +# genhtml) genhtml_sort = 1 -# Include function coverage data display -genhtml_function_coverage = 1 +# Display coverage idata in hierarchical directory structure rather than +# top/directory/source +#genhtml_hierarchical = 1 -# Location of the gcov tool -#geninfo_gcov_tool = gcov +# Display coverage data using 'flat' view: top-level table holds all +# files with no intermediate directory pages. +#genhtml_flat_view = 1 -# Adjust test names if non-zero -#geninfo_adjust_testname = 0 +# Enable hyperlinks from coverage summary table to first source code line +# in corresponding category ('Hit' or "Missed') in non-differential report. +# Feature is always enabled in differential coverage report. +#genhtml_show_navigation = 1 + +# If nonzero, add column to "function coverage detail" table to show the proportion of lines and branches within the function which are exercised. +#genhtml_show_function_proportion = 0 + +# Specify the character set of all generated HTML pages +genhtml_charset=UTF-8 + +# Allow HTML markup in test case description text if non-zero +genhtml_desc_html=0 + +# Specify the precision for coverage rates +#genhtml_precision=1 + +# Show missed counts instead of hit counts +#genhtml_missed=1 + +# group function aliases in report - see '--merge' section in man(1) genhtml +#merge_function_aliasess = 1 + +# If set, suppress list of aliases in function detail table +#suppress_function_aliases = 1 + +# If set, derive function end line from line coverpoint data - default ON +#derive_function_end_line = 1 + +# If set, derive function end lines for all file types. +# By default, we derive end lines for C/C++ files only +#derive_end_line_all_files = 0 + +# Maximum size of function (number lines) which will be checked by '--filter trivial' +#trivial_function_threshold = 5 + +# Set threshold for hit count which tool should deem likely to indicate +# a toolchain bug (corrupt coverage data) +# excessive_count_theshold = number + +# Demangle C++ symbols +# Call multiple times to specify command and command line arguments +# ('-Xlinker'-like behaviour) +#demangle_cpp = c++filt + +# Name of the tool used for demangling C++ function names +# This argument is deprecated - please use 'demangle_cpp' instead +#genhtml_demangle_cpp_tool = c++filt +# Specify extra parameters to be passed to the demangling tool +# This argument is deprecated - please use 'demangle_cpp' instead +#genhtml_demangle_cpp_params = "" -# Location of the gcov tool +# Location of the gcov tool (same as --gcov-info option of geninfo) #geninfo_gcov_tool = gcov -# Adjust test names if non-zero +# Adjust test names to include operating system information if non-zero #geninfo_adjust_testname = 0 -# Calculate a checksum for each line if non-zero -geninfo_checksum = 0 +# Ignore testcase names in .info file +#forget_testcase_names = 0 -# Enable libtool compatibility mode if non-zero -geninfo_compat_libtool = 0 +# Calculate checksum for each source code line if non-zero (same as --checksum +# option of geninfo if non-zero, same as --no-checksum if zero) +#checksum = 1 -# Specify whether to capture coverage data for external source -# files +# Specify whether to capture coverage data for external source files (can +# be overridden by the --external and --no-external options of geninfo/lcov) #geninfo_external = 1 +# Specify whether to capture coverage data from compile-time data files +# which have no corresponding runtime data. +#geninfo_capture_all = 1 + +# Enable libtool compatibility mode if non-zero (same as --compat-libtool option +# of geninfo if non-zero, same as --no-compat-libtool if zero) +#geninfo_compat_libtool = 0 + # Use gcov's --all-blocks option if non-zero #geninfo_gcov_all_blocks = 1 -# Specify compatiblity modes (same as --compat option -# of geninfo) +# Adjust 'executed' non-zero hit count of lines which contain no branches +# and have attribute '"unexecuted_blocks": true' +#geninfo_unexecuted_blocks = 0 + +# Specify compatibility modes (same as --compat option of geninfo). #geninfo_compat = libtool=on, hammer=auto, split_crc=auto -# Adjust path to source files by removing or changing path -# components that match the specified pattern (Perl regular -# expression format) +# Adjust path to source files by removing or changing path components that +# match the specified pattern (Perl regular expression format) #geninfo_adjust_src_path = /tmp/build => /usr/src -# Specify if geninfo should try to automatically determine -# the base-directory when collecting coverage data. +# Specify if geninfo should try to automatically determine the base-directory +# when collecting coverage data. geninfo_auto_base = 1 # Use gcov intermediate format? Valid values are 0, 1, auto geninfo_intermediate = auto -# Specify whether to exclude exception branches from branch coverage. -# Default is 0. -geninfo_no_exception_branch = 1 +# Specify if exception branches should be excluded from branch coverage. +no_exception_branch = 1 # Directory containing gcov kernel files -lcov_gcov_dir = /proc/gcov +# lcov_gcov_dir = /proc/gcov # Location of the insmod tool lcov_insmod_tool = /sbin/insmod @@ -116,30 +300,211 @@ lcov_rmmod_tool = /sbin/rmmod # Location for temporary directories lcov_tmp_dir = /tmp -# Show full paths during list operation if non-zero -lcov_list_full_path = 1 +# Show full paths during list operation if non-zero (same as --list-full-path +# option of lcov) +lcov_list_full_path = 0 -# Specify the maximum width for list output. This value is -# ignored when lcov_list_full_path is non-zero. +# Specify the maximum width for list output. This value is ignored when +# lcov_list_full_path is non-zero. lcov_list_width = 80 -# Specify the maximum percentage of file names which may be -# truncated when choosing a directory prefix in list output. -# This value is ignored when lcov_list_full_path is non-zero. +# Specify the maximum percentage of file names which may be truncated when +# choosing a directory prefix in list output. This value is ignored when +# lcov_list_full_path is non-zero. lcov_list_truncate_max = 20 -# Specify if function coverage data should be collected and -# processed. -lcov_function_coverage = 1 +# Specify if function coverage data should be collected, processed, and displayed +function_coverage = 1 + +# Specify if branch coverage data should be collected, processed, and displayed +branch_coverage = 0 + +# Specify if MC/DC coverage data should be collected, processed, and displayed +mcdc_coverage = 0 + +# Ask lcov/genhtml/geninfo to return non-zero exit code if branch coverage is below +# threshold +# Default is 0.0 - i.e., do not check threshold. +#fail_under_branches = 75.0 + +# Ask lcov/genhtml/geninfo to return non-zero exit code if line coverage is below +# threshold +# Default is 0.0 - i.e., do not check threshold. +#fail_under_lines = 97.5 + +# specify revision control annotation script for genhtml +#genhtml_annotate_script = path_to_my_executable + +# specify the annotation popup that will appear if user hovers over source code +# set to empty to elide tooltip +# Substitutions: +# %d: line number +# %C: commit ID (from annotate callback - see --anotate-script entry in +# genhtml documentation) +# %U: commit author abbreviated name +# %F: commit author full name +# %D: commit date (as returned by annotate callback) +# %d: simplified commit date - yyyy-mm-dd part only (remove time of day) +# %A: commit age +# %l: line number +#genhtml_annotate_tooltip = Commit ID: %C by %F on %D + +# specify coverage criteria script for genhtml/lcov/geninfo +#criteria_script = path_to_my_executable_or_module + +# specify whether you want date and/or owner information passed to your criteria +# callback - in addition to summary information, which is always returned +#criteria_callback_data = date,owner + +# specify when the criteria callback will be executed +#criteria_callback_levels = top,directory,file + +# specify callback to decide whether particular source line should be +# included or suppresses +# select_script = path_to_exe | callback_parameter + +# specify number of lines of context to include around each selected +# source line +# num_context_lines = 5 + +# specify age cutpoints for genhtml date bins +# can call option multiple times or use comma-separted list (or both) +#genhtml_date_bins = 7 +#genhtml_date_bins = 30,180 + +# if enabled, show 'author' coverpoint summary table in page headers +# if not 'all', then show only authors who are responsible for coverpoints +# which are not hit +#genhtml_show_owner_table = 0 | 1 | all + +# truncate owner table to show at most this many authors - +# subset will be those with the highest count of un-exercised code +# owner_table_entries = 5 + +# truncate the owner table at this level/these levels only +# possible values are 'file', 'directory', 'top' (without quotes) +# option may be specified multiple times and/or as a comma-separated list +# truncate_owner_table = top,directory,file + +# if enabled, show author of non-code source lines (e.g., comments) +# in 'source' detail column +#genhtml_show_noncode_owners = 0 | 1 + +# if enabled, generate fake source code for missing files and out-of-range +# lines +#genhtml_synthesize_missing = 0 | 1 + + +# ask geninfo/lcov/genhtml to include only certain files (glob match pattern) +# call multiple times to specify multiple patterns +#include = my/files/*.c +#include = my/files/*.h + +# ask geninfo/lcov/genhtml to exclude certain files (glob match pattern) +# call multiple times to specify multiple patterns +#exclude = your/files/*.c +#exclude = your/files/*.h + +# ask geninfo/lcov/genhtml to munge file pathnames when reading/writing .info files +# call multiple times to specify multiple patterns +# this pattern removes "/.lib" from the pathname (see the lcov man page for details) +#substitute = s#/.libs##g +# this pattern changes "/tmp/build" to "/usr/src" (see the lcov man page for details) +#substitute = s#/tmp/build#/usr/src#g + +# ask geninfo/lcov/genhtml to exclude coverpoints associated with lines which match +# the regexp. Call multiple times to specify multiple patterns +# omit lines which end with "// MY_LINE_EXCLUDE_MARKER +#omit_lines = .+?//\s*MY_LINE_EXCLUDE_MARKER\s* +# add another exclusion marker +#omit_lines = .+?//\s*MY_PROJECT_EXCLUDE_MARKER\s* + +# ask geninfo/lcov/genhtml to exclude coverpoints whose lines are within +# the start/end of a function matching the regexp. +#Call multiple times to specify multiple patterns +#erase_functions = main +# and another - note that this looks like a demangled C++ function +# that the argument is a regexp - so special characters need to be escaped +#erase_functions = debug)_.*\(int,\s*int\) + +# check that source file exists before calling version-script, annotate-script +# or other callback. If set and file does not exist, 'source' error is +# generated. Default: 1 (check for existence). +#check_existence_before_callback = 1 + +# specify path to version identification script +#version_script = path_to_my_executable + +# tell the tool to genenerate missing file version information when +# readind coverage DB file +# compute_file_version = 0 | 1 + +# specify path to file pathname resolution script +#resolve_script = path_to_my_executable + +# Specify JSON module to use, or choose best available if set to auto +lcov_json_module = auto -# Specify if branch coverage data should be collected and -# processed. -lcov_branch_coverage = 1 +# Specify maximum number of parallel slaves +# default: 1 (no parallelism) +#parallel = 1 -# Ask LCOV to return non-zero exit code if line coverage is -# below specified threshold percentage. -; lcov_fail_under_lines = 97.5 +# Specify maximum memory to use during parallel processing, in Mb. +# Do not fork if estimated memory consumption exceeds this number. +# default: 0 (no limit) +#memory = 1024 -# Specify JSON module to use, or choose best available if -# set to auto -lcov_json_module = auto +# Specify the number of consecutive fork() failures to allow before +# giving up +# max_fork_fails = 5 + +# Throtting control: the maximum number of files that genhtml will +# handle in a single (parallel) thread +# max_tasks_per_core = 20 + +# Seconds to wait after failing to fork() before retrying +# fork_fail_timeout = 10 + +# Throttling control: specify a percentage of system memory to use as +# maximum during parallel processing. +# Do not fork if estimated memory consumption exceeds the maximum. +# this value is used only if the maximum memory is not set. +# default: not set +#memory_percentage = 1024 + + +# Character used to split list-type parameters +# - for example, the list of "--ignore_errors source,mismatch" +# default: , (comma) +#split_char = , + +# use case insensitive compare to find matching files, for include/exclude +# directives, etc +#case_insensitive = 0 + +# override line default line exclusion regexp +#lcov_excl_line = LCOV_EXCL_LINE + +# override branch exclusion regexp +#lcov_excl_br_line = LCOV_EXCL_BR_LINE + +# override exception branch exclusion regexp +#lcov_excl_exception_br_line = LCOV_EXCL_EXCEPTION_BR_LINE + +# override start of exclude region regexp +#lcov_excl_start = LCOV_EXCL_START + +# override end of exclude region regexp +#lcov_excl_stop = LCOV_EXCL_STOP + +# override start of branch exclude region regexp +#lcov_excl_br_start = LCOV_EXCL_BR_START + +# override start of exclude region regexp +#lcov_excl_br_stop = LCOV_EXCL_BR_STOP + +# override start of exclude region regexp +#lcov_excl_exception_br_start = LCOV_EXCL_EXCEPTION_BR_START + +# override start of exclude region regexp +#lcov_excl_exception_br_stop = LCOV_EXCL_EXCEPTION_BR_STOP From 1b14661556a6c2f592bd38a844d6e367edaa0c08 Mon Sep 17 00:00:00 2001 From: Gonzalo Diaz Date: Mon, 9 Dec 2024 23:18:39 -0300 Subject: [PATCH 2/4] [CONFIG] [Github Actions] Now use fixed version of Github Actions images. --- .github/workflows/cpp.yml | 10 +++------- .github/workflows/docker-image.yml | 10 +++++----- .github/workflows/gitleaks.yml | 2 +- .github/workflows/markdown-lint.yml | 2 +- .github/workflows/yamllint.yml | 2 +- 5 files changed, 11 insertions(+), 15 deletions(-) diff --git a/.github/workflows/cpp.yml b/.github/workflows/cpp.yml index ee7cd5f..43f4381 100644 --- a/.github/workflows/cpp.yml +++ b/.github/workflows/cpp.yml @@ -1,6 +1,6 @@ --- -name: C++ CI Tests +name: C/C++ CMake CI Test on: # yamllint disable-line rule:truthy push: @@ -12,15 +12,11 @@ on: # yamllint disable-line rule:truthy jobs: build: - name: C++ CMake CI Test + name: C/C++ CMake CI Test runs-on: ubuntu-24.04 strategy: matrix: - os: [ - "windows-latest", - "ubuntu-latest", - "macOS-latest" - ] + os: ["windows-2022", "ubuntu-24.04", "macos-14"] steps: - name: Checkout repository diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index cbdd8c5..a8f9537 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -18,7 +18,7 @@ jobs: build: name: "Build Docker images" - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 @@ -73,7 +73,7 @@ jobs: lint: name: "Run in docker: LINT" - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: build steps: - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 @@ -98,7 +98,7 @@ jobs: test: name: "Run in docker: TEST" - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: build steps: - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 @@ -123,7 +123,7 @@ jobs: security: name: "Snyk Container" - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: build permissions: actions: read @@ -170,7 +170,7 @@ jobs: sarif_file: 'snyk.sarif' scan: name: "Trivy" - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: build permissions: actions: read diff --git a/.github/workflows/gitleaks.yml b/.github/workflows/gitleaks.yml index 4e087f9..cff8f02 100644 --- a/.github/workflows/gitleaks.yml +++ b/.github/workflows/gitleaks.yml @@ -20,7 +20,7 @@ on: # yamllint disable-line rule:truthy jobs: scan: name: gitleaks - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/markdown-lint.yml b/.github/workflows/markdown-lint.yml index 2a73909..82d31b5 100644 --- a/.github/workflows/markdown-lint.yml +++ b/.github/workflows/markdown-lint.yml @@ -13,7 +13,7 @@ on: # yamllint disable-line rule:truthy jobs: lint: name: Markdown Lint - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout repository diff --git a/.github/workflows/yamllint.yml b/.github/workflows/yamllint.yml index c8a8a5d..3c0fa11 100644 --- a/.github/workflows/yamllint.yml +++ b/.github/workflows/yamllint.yml @@ -13,7 +13,7 @@ on: # yamllint disable-line rule:truthy jobs: lint: name: YAML lint - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout repository uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 From f2fa35f2455664ce77465db67012d2bd71e897ba Mon Sep 17 00:00:00 2001 From: Gonzalo Diaz Date: Mon, 9 Dec 2024 23:24:44 -0300 Subject: [PATCH 3/4] [CONFIG] [Github Actions] apt-update before install new packages. --- .github/workflows/cpp-coverage.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/cpp-coverage.yml b/.github/workflows/cpp-coverage.yml index 3b5f1f7..10fc841 100644 --- a/.github/workflows/cpp-coverage.yml +++ b/.github/workflows/cpp-coverage.yml @@ -21,6 +21,7 @@ jobs: - name: Install Tools run: | + sudo apt update sudo apt-get install lcov - name: Check Tools From 8c5d4666d005422cd4b435b1b4ae3e64ab786c9e Mon Sep 17 00:00:00 2001 From: Gonzalo Diaz Date: Mon, 9 Dec 2024 23:31:59 -0300 Subject: [PATCH 4/4] [CONFIG] [Docker] * better Dockerfile to resolve some differences building images in arm64. * Base image set to current LTS specific version: Ubuntu 24.04 Noble. --- Dockerfile | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/Dockerfile b/Dockerfile index 0dadf6b..1db8eba 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,8 @@ -FROM ubuntu:24.10 AS init +FROM ubuntu:noble-20241118.1 AS init ENV WORKDIR=/app WORKDIR ${WORKDIR} +ENV VCPKG_ROOT=/opt/vcpkg RUN apt-get -y update && \ apt-get -y install --no-install-recommends --no-install-suggests make && \ @@ -13,23 +14,29 @@ ARG DEBIAN_FRONTEND=noninteractive ENV TZ=Etc/UTC # build tools -RUN apt-get update && \ - apt-get -y install --no-install-recommends --no-install-suggests build-essential cmake g++ make pkg-config && \ - rm -rf /var/lib/apt/lists/* +RUN apt-get update \ + && apt-get -y install --no-install-recommends --no-install-suggests build-essential cmake g++ make pkg-config \ + && rm -rf /var/lib/apt/lists/* \ + && make --version \ + && cmake --version \ + && g++ --version + + +ENV VCPKG_FORCE_SYSTEM_BINARIES=1 # vcpkg Package Manager -ADD https://github.com/microsoft/vcpkg/archive/refs/tags/2024.08.23.tar.gz vcpkg.tar.gz +ADD https://github.com/microsoft/vcpkg/archive/refs/tags/2024.10.21.tar.gz vcpkg.tar.gz RUN apt-get -y update && \ apt-get -y install --no-install-recommends --no-install-suggests \ - ca-certificates curl git unzip zip && \ + ca-certificates curl git ninja-build unzip zip && \ rm -rf /var/lib/apt/lists/* && \ mkdir /opt/vcpkg && \ tar xf vcpkg.tar.gz --strip-components=1 -C /opt/vcpkg && \ + rm -rf vcpkg.tar.gz && \ /opt/vcpkg/bootstrap-vcpkg.sh && \ ln -s /opt/vcpkg/vcpkg /usr/local/bin/vcpkg && \ - rm -rf vcpkg.tar.gz && \ + rm -rf /var/lib/apt/lists/* && \ vcpkg version -ENV VCPKG_ROOT=/opt/vcpkg # sources COPY ./src ${WORKDIR}/src @@ -104,7 +111,7 @@ COPY --from=builder ${WORKDIR}/build ${WORKDIR}/ CMD ["make", "test"] -FROM ubuntu:24.10 AS production +FROM ubuntu:noble-20241118.1 AS production ENV LOG_LEVEL=INFO ENV BRUTEFORCE=false