Browse Source

Merge branch 'js/compat-itimer'

Pieces to support compilation on __TANDEM.

* js/compat-itimer:
  Add a no-op setitimer() wrapper
maint
Junio C Hamano 13 years ago
parent
commit
067a1f552e
  1. 12
      Makefile
  2. 11
      git-compat-util.h

12
Makefile

@ -159,6 +159,11 @@ all:: @@ -159,6 +159,11 @@ all::
# Define NO_PREAD if you have a problem with pread() system call (e.g.
# cygwin1.dll before v1.5.22).
#
# Define NO_SETITIMER if you don't have setitimer()
#
# Define NO_STRUCT_ITIMERVAL if you don't have struct itimerval
# This also implies NO_SETITIMER
#
# Define NO_THREAD_SAFE_PREAD if your pread() implementation is not
# thread-safe. (e.g. compat/pread.c or cygwin)
#
@ -1677,6 +1682,13 @@ endif @@ -1677,6 +1682,13 @@ endif
ifdef OBJECT_CREATION_USES_RENAMES
COMPAT_CFLAGS += -DOBJECT_CREATION_MODE=1
endif
ifdef NO_STRUCT_ITIMERVAL
COMPAT_CFLAGS += -DNO_STRUCT_ITIMERVAL
NO_SETITIMER=YesPlease
endif
ifdef NO_SETITIMER
COMPAT_CFLAGS += -DNO_SETITIMER
endif
ifdef NO_PREAD
COMPAT_CFLAGS += -DNO_PREAD
COMPAT_OBJS += compat/pread.o

11
git-compat-util.h

@ -167,6 +167,17 @@ @@ -167,6 +167,17 @@
extern int compat_mkdir_wo_trailing_slash(const char*, mode_t);
#endif

#ifdef NO_STRUCT_ITIMERVAL
struct itimerval {
struct timeval it_interval;
struct timeval it_value;
}
#endif

#ifdef NO_SETITIMER
#define setitimer(which,value,ovalue)
#endif

#ifndef NO_LIBGEN_H
#include <libgen.h>
#else

Loading…
Cancel
Save