changed makefile structure M.Z.
This commit is contained in:
@ -1,72 +0,0 @@
|
||||
#---------------------------------------------------------------------------
|
||||
# Makefile for the Utilities in the utils directory,
|
||||
#
|
||||
# e.g. SerPortServer asynsrv_test
|
||||
#
|
||||
# David Maden, Sep-2000
|
||||
#--------------------------------------------------------------------------
|
||||
|
||||
#------------ for DigitalUnix (add -DFORTIFY to CFLAGS for fortified version)
|
||||
#CC = cc
|
||||
#CFLAGS = -std -g -warnprotos -I. -I../hardsup
|
||||
#BIN = ../bin
|
||||
#LFLAGS = -L../hardsup
|
||||
|
||||
#------------ for Linux
|
||||
CC = gcc
|
||||
CFLAGS = -g -I. -I../hardsup -DLinux
|
||||
BIN = ../bin
|
||||
LFLAGS = -L../hardsup -L/usr/X11R6/lib
|
||||
#------------
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
all: $(BIN)/asynsrv_test \
|
||||
$(BIN)/el734 \
|
||||
$(BIN)/el734_test \
|
||||
$(BIN)/el737 \
|
||||
$(BIN)/SerPortServer
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
$(BIN)/SerPortServer: SerPortServer.c
|
||||
rm -f $(BIN)/SerPortServer
|
||||
$(CC) $(CFLAGS) -o $(BIN)/SerPortServer \
|
||||
SerPortServer.c $(LFLAGS) -lhlib -lX11
|
||||
|
||||
|
||||
$(BIN)/asynsrv_test: asynsrv_test.c
|
||||
rm -f $(BIN)/asynsrv_test
|
||||
$(CC) $(CFLAGS) -o $(BIN)/asynsrv_test \
|
||||
asynsrv_test.c $(LFLAGS) -lhlib -lX11
|
||||
|
||||
$(BIN)/el734: el734.c
|
||||
@ echo "el734 needs Motif library. Not yet found on linux"
|
||||
rm -f $(BIN)/el734
|
||||
$(CC) $(CFLAGS) -o $(BIN)/el734 \
|
||||
el734.c $(LFLAGS) -lhlib -lX11 -lXt -lXm
|
||||
|
||||
$(BIN)/el734_test: el734_test.c
|
||||
rm -f $(BIN)/el734_test
|
||||
$(CC) $(CFLAGS) -o $(BIN)/el734_test \
|
||||
el734_test.c $(LFLAGS) -lhlib -lX11
|
||||
|
||||
$(BIN)/el737: el737.c
|
||||
@ echo "el737 needs Motif library. Not yet found on linux"
|
||||
rm -f $(BIN)/el737
|
||||
$(CC) $(CFLAGS) -I/usr/X11R6/include -o $(BIN)/el737 \
|
||||
el737.c $(LFLAGS) -lhlib -lXm -lXt -lX11 -lm
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
clean:
|
||||
- rm -f *.o
|
||||
- rm -f $(BIN)/SerPortServer \
|
||||
$(BIN)/asynsrv_test \
|
||||
$(BIN)/el734 \
|
||||
$(BIN)/el734_test \
|
||||
$(BIN)/el737
|
||||
#----------------------------------------------------------
|
||||
.c.o:
|
||||
$(CC) $(CFLAGS) -c $*.c
|
||||
#----------------------------------------------------------
|
@ -1334,7 +1334,7 @@ static int RS__MAX_ASYNCH = 20; /* Asynch "ports" 0 - 19 will be allowed */
|
||||
int tcp_option = UCX$C_TCP_PROBE_IDLE;
|
||||
#else
|
||||
int oto_len;
|
||||
#ifdef Linux
|
||||
#ifdef LINUX
|
||||
int tcp_option = 0;
|
||||
#else
|
||||
int tcp_option = TCP_KEEPINIT;
|
||||
@ -2414,7 +2414,7 @@ static int RS__MAX_ASYNCH = 20; /* Asynch "ports" 0 - 19 will be allowed */
|
||||
for (;;) {
|
||||
fflush (NULL);
|
||||
|
||||
#ifdef Linux
|
||||
#ifdef LINUX
|
||||
#define fds_bits __fds_bits
|
||||
#endif /* Linux */
|
||||
|
||||
|
1
utils/cd_obj
Normal file
1
utils/cd_obj
Normal file
@ -0,0 +1 @@
|
||||
cd ../../obj/$SICS_VERSION/psi/utils
|
50
utils/make_gen
Normal file
50
utils/make_gen
Normal file
@ -0,0 +1,50 @@
|
||||
#---------------------------------------------------------------------------
|
||||
# Makefile for the Utilities in the utils directory,
|
||||
#
|
||||
# e.g. SerPortServer asynsrv_test
|
||||
#
|
||||
# David Maden, Sep-2000
|
||||
# M.Z. Oct-2003 (system independent version)
|
||||
#--------------------------------------------------------------------------
|
||||
|
||||
.SUFFIXES:
|
||||
.SUFFIXES: .c .o
|
||||
|
||||
VPATH=$(SRC)
|
||||
ROOT=../..
|
||||
HLIB=../hardsup/libhlib.a
|
||||
LIBS = -L/usr/X11R6/lib -lX11
|
||||
#----------------------------------------------------------
|
||||
|
||||
all: asynsrv_test SerPortServer $(ALPHA)
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
SerPortServer: SerPortServer.c $(HLIB)
|
||||
$(CC) $(CFLAGS) -o $@ $Q $(LIBS)
|
||||
|
||||
asynsrv_test: asynsrv_test.c $(HLIB)
|
||||
$(CC) $(CFLAGS) -o $@ $Q $(LIBS)
|
||||
|
||||
el734: el734.c $(HLIB)
|
||||
# @ echo "el734 needs Motif library. Not yet found on linux"
|
||||
$(CC) $(CFLAGS) -o $@ $Q $(LIBS) -lXt -lXm
|
||||
|
||||
el734_test: el734_test.c $(HLIB)
|
||||
$(CC) $(CFLAGS) -o $@ $Q $(LIBS)
|
||||
|
||||
el737: el737.c $(HLIB)
|
||||
# @ echo "el737 needs Motif library. Not yet found on linux"
|
||||
$(CC) $(CFLAGS) -o $@ $Q $(LIBS) -lXm -lXt -lm
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
clean:
|
||||
- rm -f *.o
|
||||
- rm -f SerPortServer \
|
||||
asynsrv_test \
|
||||
el734 \
|
||||
el734_test \
|
||||
el737
|
||||
|
||||
#----------------------------------------------------------
|
8
utils/makefile
Normal file
8
utils/makefile
Normal file
@ -0,0 +1,8 @@
|
||||
# this makefile delegates to a version specific makefile
|
||||
|
||||
# where this subdirectory is (relative to the sics root)
|
||||
S_DOWN=psi/utils
|
||||
# where root is (from here)
|
||||
S_UP=../..
|
||||
|
||||
include ../../make_forward
|
26
utils/makefile_alpha
Normal file
26
utils/makefile_alpha
Normal file
@ -0,0 +1,26 @@
|
||||
#---------------------------------------------------------------------------
|
||||
# Makefile for the SINQ hardware utilities
|
||||
# machine-dependent part for Tru64 Unix
|
||||
#
|
||||
# Mark Koennecke, November 1996
|
||||
# Markus Zolliker, Oct 2003
|
||||
#--------------------------------------------------------------------------
|
||||
|
||||
include ../../alpha_def
|
||||
|
||||
CC = cc
|
||||
CFLAGS = -std1 -g $(DFORTIFY) -I$(SRC). -I$(ROOT)/psi/hardsup/$(SRC)
|
||||
ALPHA = el737 el734 el734_test
|
||||
|
||||
# -- the following macros are used as a replacement for some automatic variables
|
||||
# due to different make versions.
|
||||
# This is for Tru64 standard make.
|
||||
#
|
||||
# list of prerequisites including paths for VPATH
|
||||
Q=$>
|
||||
|
||||
# Fortran/C source file name
|
||||
F=$*.f
|
||||
C=$*.c
|
||||
|
||||
include make_gen
|
25
utils/makefile_linux
Normal file
25
utils/makefile_linux
Normal file
@ -0,0 +1,25 @@
|
||||
#---------------------------------------------------------------------------
|
||||
# Makefile for the SINQ hardware utilities
|
||||
# machine-dependent part for Redhat Linux with AFS at PSI
|
||||
#
|
||||
# Mark Koennecke, November 1996
|
||||
# Markus Zolliker, Oct 2003
|
||||
#--------------------------------------------------------------------------
|
||||
|
||||
include ../../$(SRC)linux_def
|
||||
|
||||
CC = gcc
|
||||
CFLAGS = -g -DLINUX $(DFORTIFY) -I$(SRC). -I$(ROOT)/psi/hardsup/$(SRC)
|
||||
|
||||
# -- the following macros are used as a replacement for some automatic variables
|
||||
# due to different make versions.
|
||||
# This is for GNU make.
|
||||
#
|
||||
# list of prerequisites including paths for VPATH
|
||||
Q=$^
|
||||
|
||||
# Fortran/C source file name
|
||||
F=$<
|
||||
C=$<
|
||||
|
||||
include $(SRC)make_gen
|
Reference in New Issue
Block a user