OSDN Git Service

NetBSD compilation fix
authorPatrick Welche <prlw1@cam.ac.uk>
Sun, 26 Apr 2009 13:49:00 +0000 (14:49 +0100)
committerJunio C Hamano <gitster@pobox.com>
Mon, 27 Apr 2009 16:54:24 +0000 (09:54 -0700)
Similar to other BSD variants, it needs USE_ST_TIMESPEC.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile
git-compat-util.h

index f006d2c..bb15c6b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -764,6 +764,7 @@ ifeq ($(uname_S),NetBSD)
        BASIC_CFLAGS += -I/usr/pkg/include
        BASIC_LDFLAGS += -L/usr/pkg/lib $(CC_LD_DYNPATH)/usr/pkg/lib
        THREADED_DELTA_SEARCH = YesPlease
+       USE_ST_TIMESPEC = YesPlease
 endif
 ifeq ($(uname_S),AIX)
        NO_STRCASESTR=YesPlease
index 785aa31..1ac16bd 100644 (file)
@@ -46,6 +46,7 @@
 #define _ALL_SOURCE 1
 #define _GNU_SOURCE 1
 #define _BSD_SOURCE 1
+#define _NETBSD_SOURCE 1
 
 #include <unistd.h>
 #include <stdio.h>