diff --git a/include/crm/Makefile.am b/include/crm/Makefile.am index 95564b8786..f965a85694 100644 --- a/include/crm/Makefile.am +++ b/include/crm/Makefile.am @@ -1,33 +1,34 @@ # -# Copyright 2004-2023 the Pacemaker project contributors +# Copyright 2004-2024 the Pacemaker project contributors # # The version control history for this file may have further details. # # This source code is licensed under the GNU General Public License version 2 # or later (GPLv2+) WITHOUT ANY WARRANTY. # MAINTAINERCLEANFILES = Makefile.in headerdir=$(pkgincludedir)/crm header_HEADERS = cib.h \ + cib_compat.h \ cluster.h \ compatibility.h \ crm.h \ crm_compat.h \ lrmd.h \ lrmd_events.h \ msg_xml.h \ msg_xml_compat.h \ services.h \ services_compat.h \ stonith-ng.h noinst_HEADERS = $(wildcard *_internal.h) SUBDIRS = common \ pengine \ cib \ fencing \ cluster diff --git a/include/crm/cib.h b/include/crm/cib.h index a93bfdea82..a1efab89a4 100644 --- a/include/crm/cib.h +++ b/include/crm/cib.h @@ -1,60 +1,57 @@ /* - * Copyright 2004-2019 the Pacemaker project contributors + * Copyright 2004-2024 the Pacemaker project contributors * * The version control history for this file may have further details. * * This source code is licensed under the GNU Lesser General Public License * version 2.1 or later (LGPLv2.1+) WITHOUT ANY WARRANTY. */ #ifndef PCMK__CRM_CIB__H # define PCMK__CRM_CIB__H # include // gboolean # include # include # include # include #ifdef __cplusplus extern "C" { #endif /** * \file * \brief Cluster Configuration * \ingroup cib */ +// Use compare_version() for doing comparisons # define CIB_FEATURE_SET "2.0" -/* use compare_version() for doing comparisons */ - -#define T_CIB_DIFF_NOTIFY "cib_diff_notify" - /* Core functions */ cib_t *cib_new(void); cib_t *cib_native_new(void); cib_t *cib_file_new(const char *filename); cib_t *cib_remote_new(const char *server, const char *user, const char *passwd, int port, gboolean encrypted); cib_t *cib_new_no_shadow(void); char *get_shadow_file(const char *name); cib_t *cib_shadow_new(const char *name); void cib_free_notify(cib_t *cib); void cib_free_callbacks(cib_t *cib); void cib_delete(cib_t * cib); void cib_dump_pending_callbacks(void); int num_cib_op_callbacks(void); void remove_cib_op_callback(int call_id, gboolean all_callbacks); # define CIB_LIBRARY "libcib.so.27" #ifdef __cplusplus } #endif #endif diff --git a/include/crm/cib_compat.h b/include/crm/cib_compat.h new file mode 100644 index 0000000000..4d028076ee --- /dev/null +++ b/include/crm/cib_compat.h @@ -0,0 +1,33 @@ +/* + * Copyright 2004-2024 the Pacemaker project contributors + * + * The version control history for this file may have further details. + * + * This source code is licensed under the GNU Lesser General Public License + * version 2.1 or later (LGPLv2.1+) WITHOUT ANY WARRANTY. + */ + +#ifndef PCMK__CRM_CIB_COMPAT__H +# define PCMK__CRM_CIB_COMPAT__H + +#ifdef __cplusplus +extern "C" { +#endif + +/** + * \file + * \brief Deprecated CIB utilities + * \ingroup core + * \deprecated Do not include this header directly. The utilities in this + * header, and the header itself, will be removed in a future + * release. + */ + +//! \deprecated Do not use +#define T_CIB_DIFF_NOTIFY "cib_diff_notify" + +#ifdef __cplusplus +} +#endif + +#endif // PCMK__CRM_CIB_COMPAT__H