7 # -mcpu= can be pentium, pentiumpro (covers PII through PIII) or pentium4
8 # -ax? specifies make code specifically for ? but compatible with IA-32
9 # -x? specifies compile solely for ? [not specifically IA-32 compatible]
13 # W - first P4 [Williamette]
16 # B - Blend of P4 and PM [mobile]
18 # Default to just generic max opts
21 # default lib name (requires install with root)
24 # libname when you can't install the lib with install
25 LIBNAME=../libtommath.a
29 $(CC) pprime.o $(LIBNAME) -o pprime
31 # portable [well requires clock()] tuning app
33 $(CC) tune.o $(LIBNAME) -o tune
35 # same app but using RDTSC for higher precision [requires 80586+], coff based gcc installs [e.g. ming, cygwin, djgpp]
37 nasm -f coff timer.asm
38 $(CC) -DX86_TIMER $(CFLAGS) tune.c timer.o $(LIBNAME) -o tune86
42 nasm -f gnuwin32 timer.asm
43 $(CC) -DX86_TIMER $(CFLAGS) tune.c timer.o $(LIBNAME) -o tune86
45 #make tune86 for linux or any ELF format
47 nasm -f elf -DUSE_ELF timer.asm
48 $(CC) -DX86_TIMER $(CFLAGS) tune.c timer.o $(LIBNAME) -o tune86l
50 # spits out mersenne primes
52 $(CC) mersenne.o $(LIBNAME) -o mersenne
54 # fines DR safe primes for the given config
56 $(CC) drprime.o $(LIBNAME) -o drprime
58 # fines 2k safe primes for the given config
60 $(CC) 2kprime.o $(LIBNAME) -o 2kprime
63 $(CC) mont.o $(LIBNAME) -o mont
67 rm -f *.log *.o *.obj *.exe pprime tune mersenne drprime tune86 tune86l mont 2kprime pprime.dat *.il