Hi! On Fri, Oct 16, 2015 at 04:58:06PM +0100, Szabolcs Nagy wrote: > #if DEFAULT_LIBC == LIBC_UCLIBC > -#define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}" > +#define CHOOSE_DYNAMIC_LINKER(G, U, M) \ > + "%{mglibc:" G ";:%{mmusl:" M ";:" U "}}" > #elif DEFAULT_LIBC == LIBC_GLIBC > -#define CHOOSE_DYNAMIC_LINKER(G, U) "%{muclibc:" U ";:" G "}" > +#define CHOOSE_DYNAMIC_LINKER(G, U, M) \ > + "%{muclibc:" U ";:%{mmusl:" M ";:" G "}}" > +#elif DEFAULT_LIBC == LIBC_MUSL > +#define CHOOSE_DYNAMIC_LINKER(G, U, M) \ > + "%{mglibc:" G ";:%{muclibc:" U ";:" M "}}" > #else > #error "Unsupported DEFAULT_LIBC" > #endif
This doesn't really scale, I wonder if some more elegant non-quadratic way is possible? Not that I expect terribly many other libcs to show up in the near future ;-) Segher