Skip to content

Commit

Permalink
donate_cpu: Check that gtk library is invoked. (#6244)
Browse files Browse the repository at this point in the history
  • Loading branch information
orbitcowboy authored Apr 6, 2024
1 parent a40fabb commit c0b5309
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
8 changes: 4 additions & 4 deletions cfg/gtk.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
<def format="2">
<define name="TRUE" value="(!FALSE)"/>
<define name="FALSE" value="(0)"/>
<define name="g_return_if_fail(expr)" value="do{if(!(expr)){return;}}while(0)"/>
<define name="g_return_val_if_fail(expr, val)" value="do{if(!(expr)){return val;}}while(0)"/>
<define name="g_return_if_reached()" value="do{return;}while(0)"/>
<define name="g_return_val_if_reached(val)" value="do{return val;}while(0)"/>
<define name="g_return_if_fail(expr)" value="do{if(!(expr)){return;}}while(0);"/>
<define name="g_return_val_if_fail(expr,val)" value="do{if(!(expr)){return (val);}}while(0);"/>
<define name="g_return_if_reached()" value="do{return;}while(0);"/>
<define name="g_return_val_if_reached(val)" value="do{return (val);}while(0);"/>
<define name="G_CALLBACK(cb)" value="cb"/>
<define name="GTK_SIGNAL_FUNC(f)" value="G_CALLBACK(f)"/>
<!-- https://developer.gnome.org/glib/stable/glib-Miscellaneous-Macros.html -->
Expand Down
4 changes: 2 additions & 2 deletions tools/donate_cpu_lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# Version scheme (MAJOR.MINOR.PATCH) should orientate on "Semantic Versioning" https://semver.org/
# Every change in this script should result in increasing the version number accordingly (exceptions may be cosmetic
# changes)
CLIENT_VERSION = "1.3.55"
CLIENT_VERSION = "1.3.56"

# Timeout for analysis with Cppcheck in seconds
CPPCHECK_TIMEOUT = 30 * 60
Expand Down Expand Up @@ -684,7 +684,7 @@ def __init__(self):
'icu': ['<unicode/', '"unicode/'],
'ginac': ['<ginac/', '"ginac/'],
'googletest': ['<gtest/gtest.h>'],
'gtk': ['<gtk', '<glib.h>', '<glib-', '<glib/', '<gnome'],
'gtk': ['<gtk', '<glib.h>', '<glib-', '<glib/', '<gdk/', '<gnome'],
'kde': ['<KGlobal>', '<KApplication>', '<KDE/'],
'libcerror': ['<libcerror.h>'],
'libcurl': ['<curl/curl.h>'],
Expand Down
3 changes: 3 additions & 0 deletions tools/donate_cpu_lib_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ def test_library_includes(tmpdir):
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'microsoft_atl'], ' \t #include <atlbase.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'cairo'], '\t #include <cairo.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'gtk'], ' \t#include <glib-object.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'gtk'], ' \t #include <glib.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'gtk'], ' # include <glib/gi18n.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'gtk'], '#include <gdk/gdkkeysyms.h>')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'bsd'], '#include <sys/uio.h>\r\n')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'libcurl'], '#include <curl/curl.h>\r')
_test_library_includes(tmpdir, ['posix', 'gnu', 'bsd', 'sqlite3'], '#include <sqlite3.h>\n')
Expand Down

0 comments on commit c0b5309

Please sign in to comment.