Commit 6433e0e9 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Don't redefine MODULE_STRING

parent 0669643b
...@@ -43,19 +43,13 @@ ...@@ -43,19 +43,13 @@
/* Explanation: /* Explanation:
* *
* if user has #defined MODULE_NAME foo, then we will need: * if HAVE_DYNAMIC_PLUGINS is NOT set, we will need:
* #define MODULE_STRING "foo"
*
* and, if HAVE_DYNAMIC_PLUGINS is NOT set, we will also need:
* #define MODULE_FUNC( zog ) module_foo_zog * #define MODULE_FUNC( zog ) module_foo_zog
* *
* this can't easily be done with the C preprocessor, thus a few ugly hacks. * this can't easily be done with the C preprocessor, thus a few ugly hacks.
*/ */
/* I can't believe I need to do this to change « foo » to « "foo" » */ /* I need to do _this_ to change « foo bar » to « module_foo_bar » ! */
#define STRINGIFY( z ) UGLY_KLUDGE( z )
#define UGLY_KLUDGE( z ) #z
/* And I need to do _this_ to change « foo bar » to « module_foo_bar » ! */
#define CONCATENATE( y, z ) CRUDE_HACK( y, z ) #define CONCATENATE( y, z ) CRUDE_HACK( y, z )
#define CRUDE_HACK( y, z ) y##__##z #define CRUDE_HACK( y, z ) y##__##z
...@@ -86,8 +80,6 @@ ...@@ -86,8 +80,6 @@
# define EXTERN_SYMBOL # define EXTERN_SYMBOL
#endif #endif
#define MODULE_STRING STRINGIFY( MODULE_NAME )
/* /*
* InitModule: this function is called once and only once, when the module * InitModule: this function is called once and only once, when the module
* is looked at for the first time. We get the useful data from it, for * is looked at for the first time. We get the useful data from it, for
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment