# If your system is BSD based, please define BSD specifically. # # If you are running Solaris, # you need to define _NO_PROTO when you compile them # you need to link your object files with -lsocket and -lnsl to make executable. CC = gcc CFLAGS = -g -D_NO_PROTO SRC = ned_cif.c ned_cli.c ned_err.c ned_sk.c OBJ = ned_cif.o ned_cli.o ned_err.o ned_sk.o all : name_resolver byname nearname nearposn iau ex_refcode ref name_resolver: libnedcli.a name_resolver.o $(CC) -o name_resolver name_resolver.o libnedcli.a -lm -lsocket -lnsl byname: libnedcli.a byname.o $(CC) -o byname byname.o $(OBJ) -lsocket -lnsl -lm nearname: libnedcli.a nearname.o $(CC) -o nearname nearname.o libnedcli.a -lm -lsocket -lnsl nearposn: libnedcli.a nearposn.o $(CC) -o nearposn nearposn.o libnedcli.a -lm -lsocket -lnsl iau: libnedcli.a iau.o $(CC) -o iau iau.o libnedcli.a -lm -lsocket -lnsl ex_refcode: libnedcli.a ex_refcode.o $(CC) -o ex_refcode ex_refcode.o libnedcli.a -lm -lsocket -lnsl ref: libnedcli.a ref.o $(CC) -o ref ref.o libnedcli.a -lm -lsocket -lnsl libnedcli.a: $(OBJ) ar rcu libnedcli.a $(OBJ) clean: \rm *.o