## Copyright (c) 1999 G. Adam Stanislav ## All rights reserved. ## ## This is a makefile for Graphic Counter Language 3.0 ## This makefile was modified for Linux by Dominique Voillemot. ## ## NOTE: ## ## On systems that allow it, GCLUSELONGLONG is defined. This makes the ## count an unsigned long long, a gcc extension that gives the counter ## 64 bits to work with on 32-bit systems, thus permitting the count ## to grow to trillions. ## ## Use maximum optimization. On busy web sites we want gracula to work as ## fast as possible. However, these options may not work with a compiler ## other than gcc. If that is the case, comment them out. VERSION=3.0 CURRENTDIR=$(shell sh -c pwd) SRCDIR=$(CURRENTDIR)/ DIST=gracula-$(VERSION) DISTDIR=$(SRCDIR) INSTALL=install BINDIR=/usr/local/bin RM=rm CFLAGS+= -O3 -fexpensive-optimizations -frerun-cse-after-loop \ -fomit-frame-pointer ## Comment out the next line if you only want 32-bit counters, ## or if you get linking errors (since it, too, may only work with gcc): CFLAGS+= -DGCLUSELONGLONG ## Comment out or change the next two lines for a different random number ## generator (note that both are prime numbers): CFLAGS+= -DGCLRNDMUL=19997 CFLAGS+= -DGCLRNDADD=2199931 LN= ln all: gracula sec2000 gracula: gcl.o gd.o ${CC} gcl.o gd.o -lc -lm -o gracula -Xlinker -s gcl.o: gcl.c gcldefaults.c gcl.h gcldefaults.h gd: gd.c mtables.c gd.h install: gracula sec2000 ${INSTALL} -c -d -m 755 -o root -g root ${BINDIR} ${INSTALL} -c -m 755 -o root -g root ${SRCDIR}gracula ${BINDIR} ${INSTALL} -c -m 755 -o root -g root ${SRCDIR}sec2000 ${BINDIR} gcl: install ${LN} -fs ${BINDIR}/gracula ${BINDIR}/gcl clean: ${RM} -f ${SRCDIR}gracula ${SRCDIR}*.o ${SRCDIR}sec2000