Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Adding version to the makefile

  • Loading branch information...
commit 162f3020f1c71dbda3ac3d931cc056820e48b12a 1 parent 9709d37
Anthony Cornehl authored

Showing 1 changed file with 14 additions and 15 deletions. Show diff stats Hide diff stats

  1. +14 15 src/Makefile
29 src/Makefile
@@ -2,6 +2,7 @@ CC:=gcc
2 2 EXE=ibniz
3 3 OPTIMIZATION:=-O2
4 4 OBJ=clipboard.o ui_sdl.o vm_slow.o
  5 +VERSION=1.18
5 6
6 7 prefix:=/usr/local
7 8 uname_S:=$(shell sh -c 'uname -s 2>/dev/null || echo not')
@@ -19,40 +20,38 @@ ifeq ($(uname_S),Darwin)
19 20 endif
20 21
21 22 ifeq (${uname_S},MINGW32_NT-5.1)
22   - # For win32 builds using mingw32 (you'll probably need to modify these)
23 23 EXE=ibniz.exe
24   - CFLAGS+=-static
  24 + CFLAGS+=-static -ffast-math -fwhole-program
25 25 LDFLAGS+=-lwinmm
26   -$(EXE): whole.c
27   - ${CC} ${CFLAGS} ${LDFLAGS} -s -ffast-math -fwhole-program whole.c -o $@
28   -
  26 + X11=no
29 27 whole.c: vm_slow.c ui_sdl.c clipboard.c texts.i font.i vm.h ibniz.h
30 28 cat ui_sdl.c vm_slow.c clipboard.c > whole.c
31   -else
32   -${EXE}: ${OBJ}
33   - ${CC} $^ ${LDFLAGS} -o ${EXE}
34   -
35 29 endif
36 30
37 31 ifneq (${X11},no)
38   - CFLAGS+=-DX11 -lX11
  32 + CFLAGS+=-DX11
39 33 LDFLAGS+=-lX11
40 34 endif
41 35
42 36 ifeq (${DEBUG},yes)
43   -CFLAGS+=-O0 -g
  37 + CFLAGS+=-O0 -g
  38 +else
  39 + CFLAGS+=-s
44 40 endif
45 41
46 42 all: ${EXE}
47 43
  44 +${EXE}: ${OBJ}
  45 + ${CC} $^ ${LDFLAGS} -o ${EXE}
  46 +
  47 +vmtest: vm_test.c vm_slow.o
  48 + ${CC} $^ ${LDFLAGS} -o $@
  49 +
48 50 clean:
49 51 rm -f *.o *~ ibniz vmtest ibniz.exe whole.c
50 52
51 53 package: clean
52   - tar -czf ibniz-1.1.tar.gz -C ../ ibniz-1.1/
53   -
54   -vmtest: vm_test.o vm_slow.o
55   - ${CC} $^ ${LDFLAGS} -o $@
  54 + tar -czf ibniz-${VERSION}.tar.gz -C ../ ibniz-${VERSION}/
56 55
57 56 ui_sdl.o: ui_sdl.c ibniz.h font.i vm.h texts.i vm.h
58 57 clipboard.o: clipboard.c ibniz.h

0 comments on commit 162f302

Please sign in to comment.
Something went wrong with that request. Please try again.