make Makefile system independent
This commit is contained in:
@ -10,18 +10,21 @@ TCLI_OBJ= sys_aunix.o sys_aunix_c.o $(CLI_OBJ)
|
|||||||
TECLI_OBJ= tecs_client.o tecs_plot.o tecs_for.o sys_util.o str.o instr_hosts.o $(TCLI_OBJ)
|
TECLI_OBJ= tecs_client.o tecs_plot.o tecs_for.o sys_util.o str.o instr_hosts.o $(TCLI_OBJ)
|
||||||
|
|
||||||
#------------ for DigitalUnix (add -DFORTIFY to CFLAGS for fortified version)
|
#------------ for DigitalUnix (add -DFORTIFY to CFLAGS for fortified version)
|
||||||
#CC=cc
|
CC_alpha_osf1=cc
|
||||||
#CFLAGS= -std1 -g -warnprotos -I../ -I. -I../hardsup -DFORTIFY
|
CFLAGS_alpha_osf1= -std1 -g -warnprotos -I../ -I. -I../hardsup
|
||||||
#CFLAGS= -std1 -g -warnprotos -I../ -I. -I../hardsup
|
#CFLAGS_alpha_osf1= -std1 -g -warnprotos -I../ -I. -I../hardsup -DFORTIFY
|
||||||
|
|
||||||
#---------- for Redhat linux
|
#---------- for Redhat linux (change redhat_linux to the corresponding $OSTYPE)
|
||||||
CC= gcc
|
CC_i386_linux= gcc
|
||||||
CFLAGS= -I/usr/local/include -I. -I../ -I../hardsup -DLINUX -g
|
CFLAGS_i386_linux= -I/usr/local/include -I. -I../ -I../hardsup -DLINUX -g
|
||||||
#------------ for Linux
|
#------------ for Linux
|
||||||
##CC=gcc
|
CC_what_linux=gcc
|
||||||
##CFLAGS = -fwritable-strings -DCYGNUS -DNONINTF -g -I../ -I. -I../hardsup
|
CFLAGS_i386_linux = -fwritable-strings -DCYGNUS -DNONINTF -g -I../ -I. -I../hardsup
|
||||||
#------------
|
#------------
|
||||||
|
|
||||||
|
CC=$(CC_$(MACHTYPE)_$(OSTYPE))
|
||||||
|
CFLAGS=$(CFLAGS_$(MACHTYPE)_$(OSTYPE))
|
||||||
|
|
||||||
.f.o:
|
.f.o:
|
||||||
f77 -c -u -g $*.f
|
f77 -c -u -g $*.f
|
||||||
|
|
||||||
@ -39,17 +42,10 @@ tecs_plot.o: tecs_plot.f90
|
|||||||
f90 -c -u -g tecs_plot.f90
|
f90 -c -u -g tecs_plot.f90
|
||||||
|
|
||||||
|
|
||||||
#------------ DigitalUnix4.0D
|
|
||||||
#bin/TecsServer: $(LIBR_OBJ) $(SERV_OBJ)
|
|
||||||
# - rm bin/TecsServer
|
|
||||||
# $(CC) $(CFLAGS) -g -o bin/TecsServer -g $(LIBR_OBJ) $(SERV_OBJ) fortify1.c \
|
|
||||||
# -lm -L../hardsup -lhlib -lfor
|
|
||||||
|
|
||||||
#---------- Linux
|
|
||||||
bin/TecsServer: $(SERV_OBJ)
|
bin/TecsServer: $(SERV_OBJ)
|
||||||
- rm bin/TecsServer
|
- rm bin/TecsServer
|
||||||
$(CC) $(CFLAGS) -o bin/TecsServer $(SERV_OBJ) fortify1.c \
|
$(CC) $(CFLAGS) -o bin/TecsServer $(SERV_OBJ) fortify1.c \
|
||||||
-lm -L../hardsup -lhlib
|
-lm -L../hardsup -lhlib
|
||||||
|
|
||||||
bin/TecsClient: $(TECLI_OBJ)
|
bin/TecsClient: $(TECLI_OBJ)
|
||||||
f77 -o bin/TecsClient -g $(TECLI_OBJ) \
|
f77 -o bin/TecsClient -g $(TECLI_OBJ) \
|
||||||
|
Reference in New Issue
Block a user