busconsole.mak 1.05 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11
PROJNAME= busconsole
APPNAME= $(PROJNAME)

USE_LUA51= YES

OPENBUSINC= ${OPENBUS_HOME}/include
OPENBUSLIB= ${OPENBUS_HOME}/lib

SRC= console.c

INCLUDES+= . $(SRCLUADIR) \
12 13 14 15 16 17 18 19 20 21
  $(OPENBUSINC)/luuid \
  $(OPENBUSINC)/lce \
  $(OPENBUSINC)/luafilesystem \
  $(OPENBUSINC)/luavararg \
  $(OPENBUSINC)/luastruct \
  $(OPENBUSINC)/luasocket2 \
  $(OPENBUSINC)/loop \
  $(OPENBUSINC)/oil \
  $(OPENBUSINC)/scs/lua \
  $(OPENBUSINC)/openbus/lua
22 23 24
LDIR+= $(OPENBUSLIB)

ifneq "$(TEC_SYSNAME)" "Darwin"
25
  LIBS += uuid
26 27
endif
ifeq "$(TEC_SYSNAME)" "Linux"
28
  LFLAGS = -Wl,-E
29 30
endif
ifeq "$(TEC_SYSNAME)" "SunOS"
31 32 33 34 35 36 37
  USE_CC=Yes
  CFLAGS= -g -KPIC -mt -D_REENTRANT
  ifeq ($(TEC_WORDSIZE), TEC_64)
    CFLAGS+= -m64
  endif
  LFLAGS= $(CFLAGS) -xildoff
  LIBS += rt
38
endif
39 40 41 42 43 44 45 46 47 48 49 50

EXTRA_SLIB= ssl uuid
OPENBUS_LIBS= crypto \
  lua5.1 luuid lce lfs luavararg luastruct luasocket \
  loop luatuple luacoroutine luacothread luainspector luaidl oil luascs luaopenbus

ifdef USE_STATIC
 SLIB= $(foreach libname, $(EXTRA_SLIB) $(OPENBUS_LIBS), $(OPENBUSLIB)/lib$(libname).a)
else
 LIBS+= dl $(OPENBUS_LIBS)
endif