* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
+#include "config.h"
#include <sys/types.h>
#include <sys/param.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <stdlib.h>
+#ifdef HAVE_STDINT_H
#include <stdint.h>
+#endif
#include <stdio.h>
#include <termios.h>
#include <fcntl.h>
#include <errno.h>
#include <unistd.h>
#include <time.h>
+#ifdef HAVE_SYS_SHA2_H
#include <sys/sha2.h>
#define SHA512_Init SHA512Init
#define SHA512_Update SHA512Update
#define SHA512_Final SHA512Final
+#else
+#include "openssl/sha.h"
+#endif
#include <sys/vfs.h>
#include <sys/statfs.h>
int getentropy(void *buf, size_t len);
+#ifdef CAN_REFERENCE_MAIN
extern int main(int, char *argv[]);
+#endif
static int gotdata(char *buf, size_t len);
static int getentropy_urandom(void *buf, size_t len, const char *path,
int devfscheck);
HX(sigprocmask(SIG_BLOCK, NULL, &sigset) == -1,
sigset);
+#ifdef CAN_REFERENCE_MAIN
HF(main); /* an addr in program */
+#endif
HF(getentropy); /* an addr in this library */
HF(printf); /* an addr in libc */
p = (char *)&p;
- Downgrade compat/getentropy_solaris.c to version 1.4 from OpenBSD.
The dl_iterate_phdr() function introduced in newer versions raises
compilation errors on solaris 10.
+ - Changes to compat/getentropy_solaris.c for,
+ ifdef stdint.h inclusion for older systems.
+ ifdef sha2.h inclusion for older systems.
6 January 2020: Wouter
- Merge #135 from Florian Obser: Use passed in neg and key cache