2 * $Id: util.h,v 1.3 2001-06-20 18:33:04 rufustfirefly Exp $
6 #define _ATALK_UTIL_H 1
12 #endif /* HAVE_UNISTD_H */
13 #include <netatalk/at.h>
15 extern unsigned const char _diacasemap[], _dialowermap[];
17 extern char **getifacelist(void);
18 extern void freeifacelist(char **);
20 #define diatolower(x) _dialowermap[(x)]
21 #define diatoupper(x) _diacasemap[(x)]
22 extern int atalk_aton __P((char *, struct at_addr *));
23 extern void bprint __P((char *, int));
24 extern int strdiacasecmp __P((const unsigned char *, const unsigned char *));
25 extern int strndiacasecmp __P((const unsigned char *, const unsigned char *,
27 extern pid_t server_lock __P((char * /*program*/, char * /*file*/,
29 #define server_unlock(x) (unlink(x))
32 extern void *mod_open __P((const char *));
33 extern void *mod_symbol __P((void *, const char *));
34 extern void mod_close __P((void *));
35 #define mod_error() ""
36 #else /* ! HAVE_DLFCN_H */
41 #endif /* ! RTLD_NOW */
43 #define mod_open(a) dlopen(a, RTLD_NOW)
45 #ifndef DLSYM_PREPEND_UNDERSCORE
46 #define mod_symbol(a, b) dlsym(a, b)
47 #else /* ! DLSYM_PREPEND_UNDERSCORE */
48 extern void *mod_symbol __P((void *, const char *));
49 #endif /* ! DLSYM_PREPEND_UNDERSCORE */
50 #define mod_error() dlerror()
51 #define mod_close(a) dlclose(a)
52 #endif /* ! HAVE_DLFCN_H */