#host system
host := $(shell gcc -dumpmachine)

# Where Asis library should be installed
INSTALL_DIR=$(HOME)/local

# Asis specific directories
GNAT_DIR=../gnat
ASIS_DIR=../asis

# System commands
CHMOD = chmod
LN = ln -s

CP = cp -p
INSTALL_FILES = cp -p
MKDIR = mkdir -p
exe_ext =
arext = .a
soext = .so
# object extension
objext = .o
RM = rm -f
RMDIR = rm -rf
AR = ar
AR_FLAGS = rc
RANLIB = ranlib
RANLIB_TEST = [ -f /usr/bin/ranlib -o -f /bin/ranlib ]
GNATMAKE_FLAGS =

ifeq "$(findstring mingw32, $(host))" "mingw32"
   CP = cp -lf
   INSTALL_FILES = cp -lf
   MKDIR = mkdir -p
   exe_ext= .exe
endif

ifeq "$(findstring OpenVMS, $(host))" "OpenVMS"
   exe_ext = .exe
   objext = .obj
   arext = .olb
   soext = .exe
   objext = .obj
   AR = lib
   AR_FLAGS = /create
   GNATMAKE_FLAGS = -nognatlib
endif

#  GNAT specific flags
ADA_FLAGS_FOR_TOOLS= -gnaty -gnatwu -gnatwe
ADA_FLAGS_FOR_ASISLIB= -gnatg -gnatwu -gnatwe

# GNATMAKE specific flags
GMFLAGS=

# GCC backend specific flags
CFLAGS= -O2 -g
CC=gcc
