]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - libctf/ctf-decls.h
libctf: fix a number of build problems found on Solaris and NetBSD
[thirdparty/binutils-gdb.git] / libctf / ctf-decls.h
1 /* Declarations for missing functions.
2 Copyright (C) 2019 Free Software Foundation, Inc.
3
4 This file is part of libctf.
5
6 libctf is free software; you can redistribute it and/or modify it under
7 the terms of the GNU General Public License as published by the Free
8 Software Foundation; either version 3, or (at your option) any later
9 version.
10
11 This program is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14 See the GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; see the file COPYING. If not see
18 <http://www.gnu.org/licenses/>. */
19
20 #ifndef _CTF_DECLS_H
21 #define _CTF_DECLS_H
22
23 #include "config.h"
24
25 #if !HAVE_DECL_QSORT_R
26 #include <stddef.h>
27 void qsort_r (void *base, size_t nmemb, size_t size,
28 int (*compar)(const void *, const void *, void *),
29 void *arg);
30 #endif /* !HAVE_DECL_QSORT_R */
31
32 #undef MAX
33 #undef MIN
34 #define MAX(a, b) ((a) > (b) ? (a) : (b))
35 #define MIN(a, b) ((a) < (b) ? (a) : (b))
36
37 #endif /* _CTF_DECLS_H */