1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-26 05:02:18 +00:00
freebsd-ports/graphics/tulip/files/patch-dirent
2012-06-14 09:47:15 +00:00

27 lines
942 B
Plaintext

--- library/tulip/src/PluginLibraryLoader.cpp.orig 2012-06-11 09:46:14.000000000 +0200
+++ library/tulip/src/PluginLibraryLoader.cpp 2012-06-13 09:50:05.000000000 +0200
@@ -191,7 +191,14 @@
}
// accepts only file whose name matches *.so or *.dylib
+#ifdef __FreeBSD__
+#include <sys/param.h>
+#if (__FreeBSD_version < 900000 && __FreeBSD_version >= 800501) || (__FreeBSD_version >= 900006)
+int __tulip_select_libs(const struct dirent *ent) {
+#else
int __tulip_select_libs(struct dirent *ent) {
+#endif /* __FreeBSD_version */
+#endif /* __FreeBSD__ */
#if !defined(__APPLE__)
const char *suffix = ".so";
const unsigned long suffix_len = 3;
@@ -216,7 +223,7 @@
struct dirent **namelist;
n = scandir((const char *) _pluginPath.c_str(),
&namelist,
-#if !(defined(__APPLE__) || defined(__FreeBSD__))
+#if !defined(__APPLE__)
(int (*) (const dirent *))
#endif
__tulip_select_libs,