mirror of https://github.com/YosysHQ/abc.git
Merged in atomb/abc (pull request #2)
More portability/flexibility fixes
This commit is contained in:
commit
5021909cb1
6
Makefile
6
Makefile
|
|
@ -38,10 +38,10 @@ default: $(PROG)
|
|||
arch_flags : arch_flags.c
|
||||
$(CC) arch_flags.c -o arch_flags
|
||||
|
||||
ARCHFLAGS := $(shell $(CC) arch_flags.c -o arch_flags && ./arch_flags)
|
||||
OPTFLAGS := -g -O #-DABC_NAMESPACE=xxx
|
||||
ARCHFLAGS ?= $(shell $(CC) arch_flags.c -o arch_flags && ./arch_flags)
|
||||
OPTFLAGS ?= -g -O #-DABC_NAMESPACE=xxx
|
||||
|
||||
CFLAGS += -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare $(OPTFLAGS) $(ARCHFLAGS) -I$(PWD)/src
|
||||
CFLAGS += -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare $(OPTFLAGS) $(ARCHFLAGS) -Isrc
|
||||
|
||||
# Set -Wno-unused-bug-set-variable for GCC 4.6.0 and greater only
|
||||
ifneq ($(or $(findstring gcc,$(CC)),$(findstring g++,$(CC))),)
|
||||
|
|
|
|||
|
|
@ -274,7 +274,7 @@ static inline int Abc_Lit2LitL( int * pMap, int Lit ) { return Abc_LitNo
|
|||
typedef ABC_INT64_T abctime;
|
||||
static inline abctime Abc_Clock()
|
||||
{
|
||||
#if (defined(LIN) || defined(LIN64) && !(__APPLE__ & __MACH__)) && !defined(__MINGW32__)
|
||||
#if (defined(LIN) || defined(LIN64)) && !(__APPLE__ & __MACH__) && !defined(__MINGW32__)
|
||||
struct timespec ts;
|
||||
if ( clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts) < 0 )
|
||||
return (abctime)-1;
|
||||
|
|
|
|||
Loading…
Reference in New Issue