diff options
Diffstat (limited to 'sysdeps/mach')
-rw-r--r-- | sysdeps/mach/hurd/xmknod.c | 17 | ||||
-rw-r--r-- | sysdeps/mach/hurd/xmknodat.c | 12 |
2 files changed, 23 insertions, 6 deletions
diff --git a/sysdeps/mach/hurd/xmknod.c b/sysdeps/mach/hurd/xmknod.c index 0ab4f1b719..a1b5af086d 100644 --- a/sysdeps/mach/hurd/xmknod.c +++ b/sysdeps/mach/hurd/xmknod.c @@ -15,12 +15,9 @@ License along with the GNU C Library; if not, see <https://www.gnu.org/licenses/>. */ -#include <errno.h> -#include <fcntl.h> -#include <stddef.h> -#include <sys/types.h> #include <sys/stat.h> - +#include <fcntl.h> +#include <shlib-compat.h> /* Create a device file named FILE_NAME, with permission and special bits MODE and device number DEV (which can be constructed from major and minor @@ -31,3 +28,13 @@ __xmknod (int vers, const char *file_name, mode_t mode, dev_t *dev) return __xmknodat (vers, AT_FDCWD, file_name, mode, dev); } libc_hidden_def (__xmknod) + +#if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_33) +int +__xmknod_compat (int vers, const char *file_name, mode_t mode, dev_t *dev) +{ + return __xmknod (vers, file_name, mode, dev); +} + +compat_symbol (libc, __xmknod_compat, __xmknod, GLIBC_2_0); +#endif diff --git a/sysdeps/mach/hurd/xmknodat.c b/sysdeps/mach/hurd/xmknodat.c index 4239d1ea91..90724694d5 100644 --- a/sysdeps/mach/hurd/xmknodat.c +++ b/sysdeps/mach/hurd/xmknodat.c @@ -26,6 +26,7 @@ #include <string.h> #include <sys/types.h> #include <sys/sysmacros.h> +#include <shlib-compat.h> /* Create a device file named PATH relative to FD, with permission and special bits MODE and device number DEV (which can be constructed @@ -116,5 +117,14 @@ __xmknodat (int vers, int fd, const char *path, mode_t mode, dev_t *dev) return __hurd_fail (err); return 0; } - libc_hidden_def (__xmknodat) + +#if SHLIB_COMPAT(libc, GLIBC_2_4, GLIBC_2_33) +int +__xmknodat_compat (int vers, int fd, const char *path, mode_t mode, dev_t *dev) +{ + return __xmknodat (vers, fd, path, mode, dev); +} + +compat_symbol (libc, __xmknodat_compat, __xmknodat, GLIBC_2_4); +#endif |