Page MenuHomeFreeBSD

D52685.diff
No OneTemporary

D52685.diff

diff --git a/lib/libc/gen/gen-compat.h b/lib/libc/gen/gen-compat.h
--- a/lib/libc/gen/gen-compat.h
+++ b/lib/libc/gen/gen-compat.h
@@ -40,24 +40,34 @@
struct freebsd11_dirent *freebsd11_readdir(DIR *);
int freebsd11_readdir_r(DIR *, struct freebsd11_dirent *,
struct freebsd11_dirent **);
-int freebsd11_stat(const char *, struct freebsd11_stat *);
-int freebsd11_lstat(const char *, struct freebsd11_stat *);
-int freebsd11_fstat(int, struct freebsd11_stat *);
-int freebsd11_fstatat(int, const char *, struct freebsd11_stat *, int);
-int freebsd11_statfs(const char *, struct freebsd11_statfs *);
-int freebsd11_getfsstat(struct freebsd11_statfs *, long, int);
int freebsd11_getmntinfo(struct freebsd11_statfs **, int);
char *freebsd11_devname(__uint32_t dev, __mode_t type);
char *freebsd11_devname_r(__uint32_t dev, __mode_t type, char *buf, int len);
-#define F14SG int freebsd14_setgroups(int gidsize, const __gid_t *gidset)
-#ifdef PIC
-static F14SG __attribute__((__weakref__("setgroups@FBSD_1.0")));
-#else
-F14SG;
-#endif
-#undef F14SG
+/*
+ * System calls.
+ */
+
+int freebsd11_stat(const char *, struct freebsd11_stat *);
+int freebsd11_lstat(const char *, struct freebsd11_stat *);
+int freebsd11_fstat(int, struct freebsd11_stat *);
+int freebsd11_fstatat(int, const char *, struct freebsd11_stat *, int);
+
+__sym_compat(stat, freebsd11_stat, FBSD_1.0);
+__sym_compat(lstat, freebsd11_lstat, FBSD_1.0);
+__sym_compat(fstat, freebsd11_fstat, FBSD_1.0);
+__sym_compat(fstatat, freebsd11_fstatat, FBSD_1.1);
+
+int freebsd11_statfs(const char *, struct freebsd11_statfs *);
+int freebsd11_getfsstat(struct freebsd11_statfs *, long, int);
+
+__sym_compat(statfs, freebsd11_statfs, FBSD_1.0);
+__sym_compat(getfsstat, freebsd11_getfsstat, FBSD_1.0);
+
+int freebsd14_setgroups(int gidsize, const __gid_t *gidset);
+
+__sym_compat(setgroups, freebsd14_setgroups, FBSD_1.0);
#endif /* _GEN_COMPAT_H_ */
diff --git a/lib/libsys/Symbol.map b/lib/libsys/Symbol.map
--- a/lib/libsys/Symbol.map
+++ b/lib/libsys/Symbol.map
@@ -4,6 +4,13 @@
__getosreldate;
__libsys_interposing_slot;
_elf_aux_info;
+ /*
+ * Note: The following system calls exports do not work, and are not
+ * needed, to fulfill references from 'libc' (see examples
+ * 'lib/libc/gen/gen-compat.h'). They are for the sake of other
+ * libraries and programs that need an explicit access to these without
+ * versioned symbols.
+ */
freebsd11_fstat;
freebsd11_fstatat;
freebsd11_getfsstat;

File Metadata

Mime Type
text/plain
Expires
Sat, Apr 25, 1:45 PM (10 h, 42 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
32128436
Default Alt Text
D52685.diff (2 KB)

Event Timeline