Fix build of bsdiff-4.3 on machines that don't have <err.h>, such as Solaris.
This commit is contained in:
parent
d63375d529
commit
af09fe12dd
3 changed files with 17 additions and 1 deletions
12
src/bsdiff-4.3/compat-include/err.h
Normal file
12
src/bsdiff-4.3/compat-include/err.h
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
/* Simulate BSD's <err.h> functionality. */
|
||||
|
||||
#ifndef COMPAT_ERR_H_INCLUDED
|
||||
#define COMPAT_ERR_H_INCLUDED 1
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#define err(rc,...) do { fprintf(stderr,__VA_ARGS__); exit(rc); } while(0)
|
||||
#define errx(rc,...) do { fprintf(stderr,__VA_ARGS__); exit(rc); } while(0)
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue