#ifdef __GNUC__
 #define DLL_PUBLIC __attribute__ ((dllexport))
#else
 #define DLL_PUBLIC __declspec(dllexport) // Note: actually gcc seems to also supports this syntax.
#endif
DLL_PUBLIC int libtest_main()
{
	return 0;
}

#if defined(__GNUC__) || defined(__clang__)
# define DLL_PUBLIC __attribute__ ((dllexport))
#else
# define DLL_PUBLIC __declspec(dllexport)
#endif
DLL_PUBLIC int libtest_main()
{
	return 0;
}

Use gcc attribute for clang too.
test.functional.c-shared-library: Use gcc attribute for clang too.
