'Doxygen skip ifdef
I am using doxygen to document my code and I have one concern. I want doxygen to record and disclose the header files. I am using ceedling for my unit tests and I often have to add helper functions for the test code to gain access to data. One of my doxygen headers is as follows.
#ifndef INCLUDE_THREAD_HEALTH_H_
#define INCLUDE_THREAD_HEALTH_H_
#include <stdbool.h>
#include <stdint.h>
#include <pthread.h>
#define MAX_TRACKED_THREADS 100U
struct thread_health {
bool thread_alive;
char* thread_name;
pthread_t* thread;
};
void thread_health_init(void);
int32_t thread_health_create_and_register_thread(pthread_t* thread, pthread_attr_t* attributes, char *thread_name, void *(*ThreadTask) (void *));
bool thread_health_destroy_unregister_thread(const pthread_t* thread);
void thread_health_task(uint32_t period);
#ifdef CEEDLING_TESTS
struct thread_health thread_health_get_health(uint8_t index);
#endif
#endif /* INCLUDE_THREAD_HEALTH_H_ */
I have the ifdef macro, I want doxygen to ignore everything in this macro. I cannot seem to find a way to do this.
Edit: Adding doxygen info
# Difference with default Doxyfile 1.8.17
PROJECT_NAME = "MAIN Application"
JAVADOC_AUTOBRIEF = YES
OPTIMIZE_OUTPUT_FOR_C = YES
RECURSIVE = YES
EXCLUDE_PATTERNS = */build/* \
*/test/*
MACRO_EXPANSION = YES
My hope was to find an undef option. But that does not seem to exist in Doxygen.
Edit 2: My defined value for my ceedling test helper functions is CEEDLING_TESTS. I would like it if Doxygen could not report the function declarations between this tag.

Edit 3: I found this in a FAQ
Unfortunately this is not working for me, it may be a version issue. I cannot find a version for the FAQ but I will attempt to update.
Edit 4: I updated to doxygen 1.9.4 following this guide. Same issue.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
