From: lzwind Date: Wed, 5 Aug 2026 01:13:34 +0000 (+0800) Subject: build: Remove G_GNUC_CONST from *_get_type declarations X-Git-Tag: archive/raspbian/2026.4-1+rpi1^2~9^2~1^2~2^2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=e87513c56081deb8b277fd2b467165c8e7f5adbe;p=ostree.git build: Remove G_GNUC_CONST from *_get_type declarations GLib removed G_GNUC_CONST from its *_get_type declarations to avoid miscompilations with GCC trunk, and recommends downstream projects do the same. See: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/5223 Closes #3612 --- diff --git a/src/libostree/ostree-async-progress.h b/src/libostree/ostree-async-progress.h index 30068923..dbc5c70e 100644 --- a/src/libostree/ostree-async-progress.h +++ b/src/libostree/ostree-async-progress.h @@ -45,7 +45,7 @@ struct OstreeAsyncProgressClass }; _OSTREE_PUBLIC -GType ostree_async_progress_get_type (void) G_GNUC_CONST; +GType ostree_async_progress_get_type (void); _OSTREE_PUBLIC OstreeAsyncProgress *ostree_async_progress_new (void); diff --git a/src/libostree/ostree-bootconfig-parser.h b/src/libostree/ostree-bootconfig-parser.h index 1ef7b7cb..944fb5bd 100644 --- a/src/libostree/ostree-bootconfig-parser.h +++ b/src/libostree/ostree-bootconfig-parser.h @@ -30,7 +30,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootconfigParser OstreeBootconfigParser; _OSTREE_PUBLIC -GType ostree_bootconfig_parser_get_type (void) G_GNUC_CONST; +GType ostree_bootconfig_parser_get_type (void); _OSTREE_PUBLIC OstreeBootconfigParser *ostree_bootconfig_parser_new (void); diff --git a/src/libostree/ostree-bootloader-aboot.h b/src/libostree/ostree-bootloader-aboot.h index 690220a5..e8d3d04d 100644 --- a/src/libostree/ostree-bootloader-aboot.h +++ b/src/libostree/ostree-bootloader-aboot.h @@ -29,7 +29,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootloaderAboot OstreeBootloaderAboot; -GType _ostree_bootloader_aboot_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_aboot_get_type (void); OstreeBootloaderAboot *_ostree_bootloader_aboot_new (OstreeSysroot *sysroot); G_END_DECLS diff --git a/src/libostree/ostree-bootloader-grub2.h b/src/libostree/ostree-bootloader-grub2.h index 8f6c3de5..47a5207d 100644 --- a/src/libostree/ostree-bootloader-grub2.h +++ b/src/libostree/ostree-bootloader-grub2.h @@ -29,7 +29,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootloaderGrub2 OstreeBootloaderGrub2; -GType _ostree_bootloader_grub2_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_grub2_get_type (void); OstreeBootloaderGrub2 *_ostree_bootloader_grub2_new (OstreeSysroot *sysroot); diff --git a/src/libostree/ostree-bootloader-syslinux.h b/src/libostree/ostree-bootloader-syslinux.h index 311e962f..24a3ee19 100644 --- a/src/libostree/ostree-bootloader-syslinux.h +++ b/src/libostree/ostree-bootloader-syslinux.h @@ -29,7 +29,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootloaderSyslinux OstreeBootloaderSyslinux; -GType _ostree_bootloader_syslinux_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_syslinux_get_type (void); OstreeBootloaderSyslinux *_ostree_bootloader_syslinux_new (OstreeSysroot *sysroot); diff --git a/src/libostree/ostree-bootloader-uboot.h b/src/libostree/ostree-bootloader-uboot.h index 8e2ed24f..f79c8e5c 100644 --- a/src/libostree/ostree-bootloader-uboot.h +++ b/src/libostree/ostree-bootloader-uboot.h @@ -33,7 +33,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootloaderUboot OstreeBootloaderUboot; -GType _ostree_bootloader_uboot_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_uboot_get_type (void); OstreeBootloaderUboot *_ostree_bootloader_uboot_new (OstreeSysroot *sysroot); diff --git a/src/libostree/ostree-bootloader-zipl.h b/src/libostree/ostree-bootloader-zipl.h index 97ba7dd0..b6056bd2 100644 --- a/src/libostree/ostree-bootloader-zipl.h +++ b/src/libostree/ostree-bootloader-zipl.h @@ -29,7 +29,7 @@ G_BEGIN_DECLS typedef struct _OstreeBootloaderZipl OstreeBootloaderZipl; -GType _ostree_bootloader_zipl_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_zipl_get_type (void); OstreeBootloaderZipl *_ostree_bootloader_zipl_new (OstreeSysroot *sysroot); G_END_DECLS diff --git a/src/libostree/ostree-bootloader.h b/src/libostree/ostree-bootloader.h index bb326f5a..522a9322 100644 --- a/src/libostree/ostree-bootloader.h +++ b/src/libostree/ostree-bootloader.h @@ -49,7 +49,7 @@ struct _OstreeBootloaderInterface }; G_DEFINE_AUTOPTR_CLEANUP_FUNC (OstreeBootloader, g_object_unref) -GType _ostree_bootloader_get_type (void) G_GNUC_CONST; +GType _ostree_bootloader_get_type (void); gboolean _ostree_bootloader_query (OstreeBootloader *bootloader, gboolean *out_is_active, GCancellable *cancellable, GError **error); diff --git a/src/libostree/ostree-chain-input-stream.h b/src/libostree/ostree-chain-input-stream.h index d6396774..26e8d005 100644 --- a/src/libostree/ostree-chain-input-stream.h +++ b/src/libostree/ostree-chain-input-stream.h @@ -64,7 +64,7 @@ struct _OstreeChainInputStreamClass }; _OSTREE_PUBLIC -GType ostree_chain_input_stream_get_type (void) G_GNUC_CONST; +GType ostree_chain_input_stream_get_type (void); _OSTREE_PUBLIC OstreeChainInputStream *ostree_chain_input_stream_new (GPtrArray *streams); diff --git a/src/libostree/ostree-checksum-input-stream.h b/src/libostree/ostree-checksum-input-stream.h index 1c5cc371..2e9543b2 100644 --- a/src/libostree/ostree-checksum-input-stream.h +++ b/src/libostree/ostree-checksum-input-stream.h @@ -63,7 +63,7 @@ struct _OstreeChecksumInputStreamClass }; _OSTREE_PUBLIC -GType ostree_checksum_input_stream_get_type (void) G_GNUC_CONST; +GType ostree_checksum_input_stream_get_type (void); _OSTREE_PUBLIC OstreeChecksumInputStream *ostree_checksum_input_stream_new (GInputStream *stream, diff --git a/src/libostree/ostree-deployment.h b/src/libostree/ostree-deployment.h index afa71fb2..3d92fd28 100644 --- a/src/libostree/ostree-deployment.h +++ b/src/libostree/ostree-deployment.h @@ -41,7 +41,7 @@ G_BEGIN_DECLS typedef struct _OstreeDeployment OstreeDeployment; _OSTREE_PUBLIC -GType ostree_deployment_get_type (void) G_GNUC_CONST; +GType ostree_deployment_get_type (void); _OSTREE_PUBLIC guint ostree_deployment_hash (gconstpointer v); diff --git a/src/libostree/ostree-fetcher.h b/src/libostree/ostree-fetcher.h index 59ae633b..52c82122 100644 --- a/src/libostree/ostree-fetcher.h +++ b/src/libostree/ostree-fetcher.h @@ -83,7 +83,7 @@ char *_ostree_fetcher_uri_to_string (OstreeFetcherURI *uri); gboolean _ostree_fetcher_uri_validate (OstreeFetcherURI *uri, GError **error); -GType _ostree_fetcher_get_type (void) G_GNUC_CONST; +GType _ostree_fetcher_get_type (void); OstreeFetcher *_ostree_fetcher_new (int tmpdir_dfd, const char *remote_name, OstreeFetcherConfigFlags flags); diff --git a/src/libostree/ostree-libarchive-input-stream.h b/src/libostree/ostree-libarchive-input-stream.h index 8ab22038..0d906c82 100644 --- a/src/libostree/ostree-libarchive-input-stream.h +++ b/src/libostree/ostree-libarchive-input-stream.h @@ -66,7 +66,7 @@ struct _OstreeLibarchiveInputStreamClass void (*_g_reserved5) (void); }; -GType _ostree_libarchive_input_stream_get_type (void) G_GNUC_CONST; +GType _ostree_libarchive_input_stream_get_type (void); GInputStream *_ostree_libarchive_input_stream_new (struct archive *a); diff --git a/src/libostree/ostree-lzma-compressor.h b/src/libostree/ostree-lzma-compressor.h index 570bc33e..bcf8457e 100644 --- a/src/libostree/ostree-lzma-compressor.h +++ b/src/libostree/ostree-lzma-compressor.h @@ -42,7 +42,7 @@ struct _OstreeLzmaCompressorClass GObjectClass parent_class; }; -GType _ostree_lzma_compressor_get_type (void) G_GNUC_CONST; +GType _ostree_lzma_compressor_get_type (void); OstreeLzmaCompressor *_ostree_lzma_compressor_new (GVariant *params); diff --git a/src/libostree/ostree-lzma-decompressor.h b/src/libostree/ostree-lzma-decompressor.h index a60745fe..1a73df06 100644 --- a/src/libostree/ostree-lzma-decompressor.h +++ b/src/libostree/ostree-lzma-decompressor.h @@ -44,7 +44,7 @@ struct _OstreeLzmaDecompressorClass }; GLIB_AVAILABLE_IN_ALL -GType _ostree_lzma_decompressor_get_type (void) G_GNUC_CONST; +GType _ostree_lzma_decompressor_get_type (void); GLIB_AVAILABLE_IN_ALL OstreeLzmaDecompressor *_ostree_lzma_decompressor_new (void); diff --git a/src/libostree/ostree-metalink.h b/src/libostree/ostree-metalink.h index a4575155..20e4643b 100644 --- a/src/libostree/ostree-metalink.h +++ b/src/libostree/ostree-metalink.h @@ -43,7 +43,7 @@ struct OstreeMetalinkClass }; G_DEFINE_AUTOPTR_CLEANUP_FUNC (OstreeMetalink, g_object_unref) -GType _ostree_metalink_get_type (void) G_GNUC_CONST; +GType _ostree_metalink_get_type (void); OstreeMetalink *_ostree_metalink_new (OstreeFetcher *fetcher, const char *requested_file, guint64 max_size, OstreeFetcherURI *uri, diff --git a/src/libostree/ostree-mutable-tree.h b/src/libostree/ostree-mutable-tree.h index 923b2cd2..4564b55b 100644 --- a/src/libostree/ostree-mutable-tree.h +++ b/src/libostree/ostree-mutable-tree.h @@ -49,7 +49,7 @@ struct OstreeMutableTreeClass }; _OSTREE_PUBLIC -GType ostree_mutable_tree_get_type (void) G_GNUC_CONST; +GType ostree_mutable_tree_get_type (void); _OSTREE_PUBLIC OstreeMutableTree *ostree_mutable_tree_new (void); diff --git a/src/libostree/ostree-remote.h b/src/libostree/ostree-remote.h index 066322f8..2a1e7be4 100644 --- a/src/libostree/ostree-remote.h +++ b/src/libostree/ostree-remote.h @@ -44,7 +44,7 @@ G_BEGIN_DECLS */ _OSTREE_PUBLIC -GType ostree_remote_get_type (void) G_GNUC_CONST; +GType ostree_remote_get_type (void); _OSTREE_PUBLIC OstreeRemote *ostree_remote_ref (OstreeRemote *remote); _OSTREE_PUBLIC diff --git a/src/libostree/ostree-repo-file-enumerator.h b/src/libostree/ostree-repo-file-enumerator.h index a67ac9d0..e37cbf94 100644 --- a/src/libostree/ostree-repo-file-enumerator.h +++ b/src/libostree/ostree-repo-file-enumerator.h @@ -46,7 +46,7 @@ struct _OstreeRepoFileEnumeratorClass }; G_GNUC_INTERNAL -GType _ostree_repo_file_enumerator_get_type (void) G_GNUC_CONST; +GType _ostree_repo_file_enumerator_get_type (void); G_GNUC_INTERNAL GFileEnumerator *_ostree_repo_file_enumerator_new (OstreeRepoFile *dir, const char *attributes, diff --git a/src/libostree/ostree-repo-file.h b/src/libostree/ostree-repo-file.h index 309e2964..77d51ff9 100644 --- a/src/libostree/ostree-repo-file.h +++ b/src/libostree/ostree-repo-file.h @@ -43,7 +43,7 @@ struct _OstreeRepoFileClass }; _OSTREE_PUBLIC -GType ostree_repo_file_get_type (void) G_GNUC_CONST; +GType ostree_repo_file_get_type (void); _OSTREE_PUBLIC gboolean ostree_repo_file_ensure_resolved (OstreeRepoFile *self, GError **error); diff --git a/src/libostree/ostree-repo-private.h b/src/libostree/ostree-repo-private.h index ddaf5e78..819842f9 100644 --- a/src/libostree/ostree-repo-private.h +++ b/src/libostree/ostree-repo-private.h @@ -468,7 +468,7 @@ OstreeRepoAutoTransaction *_ostree_repo_auto_transaction_new (OstreeRepo *repo); typedef struct OstreeComposefsTarget OstreeComposefsTarget; -GType ostree_composefs_target_get_type (void) G_GNUC_CONST; +GType ostree_composefs_target_get_type (void); OstreeComposefsTarget *ostree_composefs_target_new (void); OstreeComposefsTarget *ostree_composefs_target_ref (OstreeComposefsTarget *target); void ostree_composefs_target_unref (OstreeComposefsTarget *target); diff --git a/src/libostree/ostree-tls-cert-interaction-private.h b/src/libostree/ostree-tls-cert-interaction-private.h index 0aca097a..9c3af524 100644 --- a/src/libostree/ostree-tls-cert-interaction-private.h +++ b/src/libostree/ostree-tls-cert-interaction-private.h @@ -40,7 +40,7 @@ typedef struct _OstreeTlsCertInteraction OstreeTlsCertInteraction; typedef struct _OstreeTlsCertInteractionClass OstreeTlsCertInteractionClass; G_DEFINE_AUTOPTR_CLEANUP_FUNC (OstreeTlsCertInteraction, g_object_unref) -GType _ostree_tls_cert_interaction_get_type (void) G_GNUC_CONST; +GType _ostree_tls_cert_interaction_get_type (void); OstreeTlsCertInteraction *_ostree_tls_cert_interaction_new (const char *cert_path, const char *key_path); diff --git a/src/libotutil/ot-checksum-instream.h b/src/libotutil/ot-checksum-instream.h index 096d43c3..9e3dbbfe 100644 --- a/src/libotutil/ot-checksum-instream.h +++ b/src/libotutil/ot-checksum-instream.h @@ -52,7 +52,7 @@ struct _OtChecksumInstreamClass GFilterInputStreamClass parent_class; }; -GType ot_checksum_instream_get_type (void) G_GNUC_CONST; +GType ot_checksum_instream_get_type (void); OtChecksumInstream *ot_checksum_instream_new (GInputStream *stream, GChecksumType checksum); OtChecksumInstream *ot_checksum_instream_new_with_start (GInputStream *stream,