aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/libbb.h8
-rw-r--r--include/platform.h2
2 files changed, 8 insertions, 2 deletions
diff --git a/include/libbb.h b/include/libbb.h
index cae54658b..135d9111d 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -106,7 +106,11 @@
# define updwtmpx updwtmp
# define _PATH_UTMPX _PATH_UTMP
# else
-# include <utmp.h>
+# if !defined(__FreeBSD__)
+# include <utmp.h>
+# else
+# define _PATH_UTMPX "/var/run/utx.active"
+# endif
# include <utmpx.h>
# if defined _PATH_UTMP && !defined _PATH_UTMPX
# define _PATH_UTMPX _PATH_UTMP
@@ -657,6 +661,7 @@ void parse_datestr(const char *date_str, struct tm *ptm) FAST_FUNC;
time_t validate_tm_time(const char *date_str, struct tm *ptm) FAST_FUNC;
char *strftime_HHMMSS(char *buf, unsigned len, time_t *tp) FAST_FUNC;
char *strftime_YYYYMMDDHHMMSS(char *buf, unsigned len, time_t *tp) FAST_FUNC;
+void xgettimeofday(struct timeval *tv) FAST_FUNC;
void xsettimeofday(const struct timeval *tv) FAST_FUNC;
@@ -869,6 +874,7 @@ char *xmalloc_substitute_string(const char *src, int count, const char *sub, con
int bb_putchar(int ch) FAST_FUNC;
/* Note: does not use stdio, writes to fd 2 directly */
int bb_putchar_stderr(char ch) FAST_FUNC;
+int fputs_stdout(const char *s) FAST_FUNC;
char *xasprintf(const char *format, ...) __attribute__ ((format(printf, 1, 2))) FAST_FUNC RETURNS_MALLOC;
char *auto_string(char *str) FAST_FUNC;
// gcc-4.1.1 still isn't good enough at optimizing it
diff --git a/include/platform.h b/include/platform.h
index 085387fd8..d991f3140 100644
--- a/include/platform.h
+++ b/include/platform.h
@@ -319,7 +319,7 @@ typedef unsigned smalluint;
#endif
/* Define bb_setpgrp */
-#if defined(__digital__) && defined(__unix__)
+#if (defined(__digital__) && defined(__unix__)) || defined(__FreeBSD__)
/* use legacy setpgrp(pid_t, pid_t) for now. move to platform.c */
# define bb_setpgrp() do { pid_t __me = getpid(); setpgrp(__me, __me); } while (0)
#else