version 1.1.1.1, 1999/10/08 02:12:01 |
version 1.11, 2000/12/25 06:19:11 |
|
|
|
### $OpenXM: OpenXM/src/kan96xx/Kan/Makefile,v 1.10 2000/09/17 03:12:11 takayama Exp $ |
all : sm1 |
all : sm1 |
|
# .SUFFIXES: |
########################## configuration ############################## |
########################## configuration ############################## |
|
TOPDIR=../../../../OpenXM |
|
OpenXM_HOME=${TOPDIR} |
|
OpenXM_include=$(OpenXM_HOME)/include |
#### What C compiler do you use? |
#### What C compiler do you use? |
CC = gcc |
CC = gcc |
#### Gargabe collector? If GC = nogc.c, then you need to define -DNOGC. |
#### Gargabe collector? If GC = nogc.c, then you need to define -DNOGC. |
GC = ../gc/gc.a |
GC = $(OpenXM_HOME)/lib/libgc.a |
##GC = /fuji/taka/noro/libgc.a |
|
##GC = /dosc/work/noro/libgc.a |
|
#GC = nogc.c |
#GC = nogc.c |
#### -D options |
#### -D options |
DDD = |
DDD = -D_BSD_SOURCE |
#DDD = -DNOGC |
#DDD = -DNOGC -D_BSD_SOURCE |
|
#STATIC_LINK_FLAG = -static |
|
STATIC_LINK_FLAG = |
|
|
#### Optimization level etc. |
#### Optimization level etc. |
#CFLAGS = |
#CFLAGS = |
|
|
#### profiler to output mon.out |
#### profiler to output mon.out |
#CFLAGS = -O |
#CFLAGS = -O |
|
|
GMP_HOME = ../gmp |
|
GMP_HOME2 = ../../gmp |
GMP_HOME2 = ../../gmp |
LIBGMP=$(GMP_HOME)/libgmp.a |
LIBGMP = $(OpenXM_HOME)/lib/libgmp.so -Wl,--rpath -Wl,$(OpenXM_HOME)/lib |
## This line is for buggy linux-gmp. |
## This line is for buggy linux-gmp. |
##LIBGMP = $(GMP_HOME)/libgmp.a $(GMP_HOME)/mpn/libmpn.a |
##LIBGMP = $(GMP_HOME)/libgmp.a $(GMP_HOME)/mpn/libmpn.a |
|
|
SOLARISLIB = |
## Library you need on Solaris 2.* |
## If you are using Solaris 2.x and you need to compile sm1 with socket |
SOLARISLIB = -lnsl -lsocket /usr/ucblib/libucb.a |
## interface (make sm1_socket), uncommnet the following line. |
|
## SOLARISLIB = -lnsl -lsocket /usr/ucblib/libucb.a |
|
|
|
################### Plugin modules |
################### Plugin modules |
## Note that you need to make PLUGIN_LIB by your hand. |
## Note that you need to make PLUGIN_LIB by your hand. |
Line 78 PLUGIN_LINKFLAG = |
|
Line 80 PLUGIN_LINKFLAG = |
|
#HEADERS = datatype.h stackm.h lookup.h extern.h kclass.h Makefile |
#HEADERS = datatype.h stackm.h lookup.h extern.h kclass.h Makefile |
HEADERS = datatype.h stackm.h lookup.h extern.h kclass.h |
HEADERS = datatype.h stackm.h lookup.h extern.h kclass.h |
.c.o : |
.c.o : |
$(CC) -I$(GMP_HOME) $(CFLAGS) $(DDD) -c $< |
$(CC) -I$(OpenXM_include) $(CFLAGS) $(DDD) -c $< |
|
|
kanlibP = kanExport0.o kanExport1.o |
kanlibP = kanExport0.o kanExport1.o |
kanlibS1 = stackmachine.o |
kanlibS1 = stackmachine.o |
Line 127 ext.o : extern2.h $(HEADERS) plugin.h plugin.hh |
|
Line 129 ext.o : extern2.h $(HEADERS) plugin.h plugin.hh |
|
|
|
MSG0 = msg0.o |
MSG0 = msg0.o |
|
|
sm1 : sm.c $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanlibS4) $(kanlibP) $(kanlibK) $(kanlibK2) $(kanlibKclass) $(PLUGIN_LIB) $(GC) |
sm1 : sm.c $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanlibS4) $(kanlibP) $(kanlibK) $(kanlibK2) $(kanlibKclass) $(PLUGIN_LIB) ${GC} |
$(CC) -I$(GMP_HOME) $(CFLAGS) $(DDD) -o sm1 sm.c $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanlibS4) $(kanlibP) $(kanlibK) $(kanlibK2) $(kanlibKclass) $(PLUGIN_LIB) $(LIBGMP) $(GC) $(PLUGIN_LINKFLAG) $(SOLARISLIB) |
if test `uname` = "SunOS" ; \ |
|
then \ |
|
$(CC) -I$(OpenXM_include) $(CFLAGS) $(DDD) -o sm1 sm.c $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanlibS4) $(kanlibP) $(kanlibK) $(kanlibK2) $(kanlibKclass) $(PLUGIN_LIB) $(LIBGMP) ${GC} $(PLUGIN_LINKFLAG) $(SOLARISLIB) ; \ |
|
else \ |
|
$(CC) ${STATIC_LINK_FLAG} -I$(OpenXM_include) $(CFLAGS) $(DDD) -o sm1 sm.c $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanlibS4) $(kanlibP) $(kanlibK) $(kanlibK2) $(kanlibKclass) $(PLUGIN_LIB) $(LIBGMP) ${GC} $(PLUGIN_LINKFLAG) ; \ |
|
fi |
|
|
|
|
$(kanlibP) : $(HEADERS) gradedset.h extern2.h |
$(kanlibP) : $(HEADERS) gradedset.h extern2.h |
$(kanlibS1) : $(HEADERS) smacro.h gradedset.h |
$(kanlibS1) : $(HEADERS) smacro.h gradedset.h |
$(kanlibS2) : $(HEADERS) gradedset.h extern2.h |
$(kanlibS2) : $(HEADERS) gradedset.h extern2.h |
Line 143 kanlib.a : $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanli |
|
Line 151 kanlib.a : $(kanlibS1) $(kanlibS2) $(kanlibS3) $(kanli |
|
../gc/if_not_there ../gc/on_sparc_sunos5 ranlib kanlib.a |
../gc/if_not_there ../gc/on_sparc_sunos5 ranlib kanlib.a |
|
|
##sm1 : sm.c kanlib.a $(GC) |
##sm1 : sm.c kanlib.a $(GC) |
## $(CC) -I$(GMP_HOME) $(CFLAGS) $(DDD) -o sm1 sm.c kanlib.a $(LIBGMP) $(GC) $(SOLARISLIB) $(PLUGIN_LINKFLAG) |
## $(CC) -I$(OpenXM_include) $(CFLAGS) $(DDD) -o sm1 sm.c kanlib.a $(LIBGMP) $(GC) $(SOLARISLIB) $(PLUGIN_LINKFLAG) |
|
|
|
|
############ smacro.h and lookup.h |
############ smacro.h and lookup.h |
Line 160 lookup.h : stackm.h mklookup |
|
Line 168 lookup.h : stackm.h mklookup |
|
mm : mm.c |
mm : mm.c |
$(CC) -o mm mm.c |
$(CC) -o mm mm.c |
mklookup : mklookup.c |
mklookup : mklookup.c |
$(CC) -I$(GMP_HOME) -o mklookup mklookup.c |
$(CC) -I$(OpenXM_include) -o mklookup mklookup.c |
|
|
############# sm1 stack machine without algebraic part. |
############# sm1 stack machine without algebraic part. |
sm00 : sm.c $(kanlibS1) $(kanlibS2) $(kanlibP) $(PLUGIN_LIB) $(GC) |
sm00 : sm.c $(kanlibS1) $(kanlibS2) $(kanlibP) $(PLUGIN_LIB) ${GC} |
$(CC) -I$(GMP_HOME) $(CFLAGS) $(DDD) -o sm00 sm.c $(kanlibS1) $(kanlibS2) $(PLUGIN_LIB) $(LIBGMP) $(GC) $(PLUGIN_LINKFLAG) $(SOLARISLIB) |
$(CC) -I$(OpenXM_include) $(CFLAGS) $(DDD) -o sm00 sm.c $(kanlibS1) $(kanlibS2) $(PLUGIN_LIB) $(LIBGMP) ${GC} $(PLUGIN_LINKFLAG) $(SOLARISLIB) |
|
|
############### plugins |
############### plugins |
plugin.hh : Makefile $(PLUGIN_EXT) |
plugin.hh : Makefile $(PLUGIN_EXT) |