{"thread":{"id":"63131","subject":"[PATCH 01/12] meson.build: remove -DCURL_DISABLE_TYPECHECK","startedAt":"2025-03-15T02:49:26Z","lastAt":"2025-03-19T13:36:53Z","messageCount":2,"participants":["Ramsay Jones","Patrick Steinhardt"],"isPatch":true,"patchVersion":1,"patchTotal":12},"messages":[{"id":"514344","messageId":"d230e5a7-1b3d-4cf9-b30e-69471d1fbe9a@ramsayjones.plus.com","threadId":"63131","inReplyTo":null,"subject":"[PATCH 01/12] meson.build: remove -DCURL_DISABLE_TYPECHECK","fromName":"Ramsay Jones","fromEmail":"ramsay@ramsayjones.plus.com","sentAt":"2025-03-15T02:46:23Z","receivedAt":"2025-03-15T02:49:26Z","isPatch":true,"sender":{"key":"ramsay@ramsayjones.plus.com","avatar":"https://avatars.githubusercontent.com/u/33702710?v=4"},"body":"\nCommit 9371322a60 (\"sparse: suppress some \\\"using sizeof on a function\\\"\nwarnings\", 2013-10-06) used target-specific variable assignments to add\n-DCURL_DISABLE_TYPECHECK to SPARSE_FLAGS for each of the files affected\nby the \"typecheck-gcc.h\" warnings. (http-push.c, http.c, http-walker.c\nand remote-curl.c).\n\nThese warnings are only issued by sparse, and not by gcc, so we do not\nwant to disable the 'type checking' for non-sparse targets. The meson\nbuild does not provide any sparse targets, so there is no need to use\nthe CURL_DISABLE_TYPECHECK preprocessor flag with the c compiler.\n\nIn order to re-enable the curl 'type checking' in the meson build, remove\nthe assignment of -DCURL_DISABLE_TYPECHECK to libgit_c_args.\n\nSigned-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>\n---\n meson.build | 1 -\n 1 file changed, 1 deletion(-)\n\ndiff --git a/meson.build b/meson.build\nindex efe2871c9d..88a29fd043 100644\n--- a/meson.build\n+++ b/meson.build\n@@ -966,7 +966,6 @@ if curl.found()\n   # Most executables don't have to link against libcurl, but we still need its\n   # include directories so that we can resolve LIBCURL_VERSION in \"help.c\".\n   libgit_dependencies += curl.partial_dependency(includes: true)\n-  libgit_c_args += '-DCURL_DISABLE_TYPECHECK'\n   build_options_config.set('NO_CURL', '')\n else\n   libgit_c_args += '-DNO_CURL'\n-- \n2.49.0\n"},{"id":"514639","messageId":"Z9rIcPprrsKtJkmV@pks.im","threadId":"63131","inReplyTo":"d230e5a7-1b3d-4cf9-b30e-69471d1fbe9a@ramsayjones.plus.com","subject":"Re: [PATCH 01/12] meson.build: remove -DCURL_DISABLE_TYPECHECK","fromName":"Patrick Steinhardt","fromEmail":"ps@pks.im","sentAt":"2025-03-19T13:36:48Z","receivedAt":"2025-03-19T13:36:53Z","isPatch":true,"sender":{"key":"ps@pks.im","avatar":"https://avatars.githubusercontent.com/u/4056630?v=4"},"body":"On Sat, Mar 15, 2025 at 02:46:23AM +0000, Ramsay Jones wrote:\n> \n> Commit 9371322a60 (\"sparse: suppress some \\\"using sizeof on a function\\\"\n> warnings\", 2013-10-06) used target-specific variable assignments to add\n> -DCURL_DISABLE_TYPECHECK to SPARSE_FLAGS for each of the files affected\n> by the \"typecheck-gcc.h\" warnings. (http-push.c, http.c, http-walker.c\n> and remote-curl.c).\n> \n> These warnings are only issued by sparse, and not by gcc, so we do not\n> want to disable the 'type checking' for non-sparse targets. The meson\n> build does not provide any sparse targets, so there is no need to use\n> the CURL_DISABLE_TYPECHECK preprocessor flag with the c compiler.\n> \n> In order to re-enable the curl 'type checking' in the meson build, remove\n> the assignment of -DCURL_DISABLE_TYPECHECK to libgit_c_args.\n> \n> Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>\n\nMakes sense indeed.\n\nPatrick\n"}]}