# A long time ago, far, far away, under Solaris, you needed to # CFLAGS += -xO2 -Xc # LDLIBS += -lnsl -lsocket # To cross-compile # CC = arm-linux-gcc # To check for lint # CFLAGS += -Wpointer-arith -Wcast-align -Wcast-qual -Wshadow -Wundef \ # -Waggregate-return -Wnested-externs -Winline -Wwrite-strings -Wstrict-prototypes # This is old-school networking code, making the traditional cast between # struct sockaddr* and struct sockaddr_in*. Thus a modern gcc needs: override CFLAGS += -fno-strict-aliasing override CFLAGS += -std=c89 override CFLAGS += -W -Wall override CFLAGS += -O2 # CFLAGS += -DPRECISION_SIOCGSTAMP override CFLAGS += -DENABLE_DEBUG override CFLAGS += -DENABLE_REPLAY # CFLAGS += -DUSE_OBSOLETE_GETTIMEOFDAY override LDFLAGS += -Wl,--no-as-needed override LDFLAGS += -Wl,-lrt all: ntpclient test: ntpclient ./ntpclient -d -r