aboutsummaryrefslogtreecommitdiffstats
path: root/common.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2022-02-13 00:28:37 +0100
committerMattias Andrée <maandree@kth.se>2022-02-13 00:28:37 +0100
commit2ef79ab9d01090c1b3a2cc445a18d141cbb3c781 (patch)
tree1a455cc6d734f4b63adaf7857e4747dd2ed8ffcb /common.h
downloadlibar2simplified-2ef79ab9d01090c1b3a2cc445a18d141cbb3c781.tar.gz
libar2simplified-2ef79ab9d01090c1b3a2cc445a18d141cbb3c781.tar.bz2
libar2simplified-2ef79ab9d01090c1b3a2cc445a18d141cbb3c781.tar.xz
First commit
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'common.h')
-rw-r--r--common.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/common.h b/common.h
new file mode 100644
index 0000000..cb6a5fe
--- /dev/null
+++ b/common.h
@@ -0,0 +1,33 @@
+/* See LICENSE file for copyright and license details. */
+#include "libar2simplified.h"
+
+#include <ctype.h>
+#include <errno.h>
+#include <limits.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+
+#include <libar2.h>
+
+
+#ifndef ALIGNOF
+# ifdef __STDC_VERSION__
+# if __STDC_VERSION__ >= 201112L
+# define ALIGNOF(X) _Alignof(X)
+# endif
+# endif
+#endif
+#ifndef ALIGNOF
+# ifdef __GNUC__
+# define ALIGNOF(X) __alignof__(X)
+# else
+# define ALIGNOF(X) sizeof(X)
+# endif
+#endif
+
+
+#ifndef FALLBACK_NPROC
+# define FALLBACK_NPROC 4
+#endif