2
* libcompat - system compatibility library
3
* compat.h - system compatibility declarations
5
* Copyright © 1995 Ian Jackson <ian@chiark.greenend.org.uk>
6
* Copyright © 2008 Guillem Jover <guillem@debian.org>
8
* This is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as
10
* published by the Free Software Foundation; either version 2,
11
* or (at your option) any later version.
13
* This is distributed in the hope that it will be useful, but
14
* WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License for more details.
18
* You should have received a copy of the GNU General Public
19
* License along with dpkg; if not, write to the Free Software
20
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
31
#define offsetof(st, m) ((size_t)&((st *)NULL)->m)
35
* Define WCOREDUMP if we don't have it already, coredumps won't be
39
#define WCOREDUMP(x) 0
43
#define strtoul strtol
47
#define va_copy(dest, src) (dest) = (src)
53
const char *strerror(int);
56
#ifndef HAVE_STRSIGNAL
57
const char *strsignal(int);
62
int scandir(const char *dir, struct dirent ***namelist,
63
int (*filter)(const struct dirent *),
64
int (*cmp)(const void *, const void *));
67
#ifndef HAVE_ALPHASORT
68
int alphasort(const void *a, const void *b);
72
int unsetenv(const char *x);