File: makefile

package info (click to toggle)
kball 0.0.20041216-6
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 10,820 kB
  • ctags: 523
  • sloc: cpp: 4,149; makefile: 110; sh: 64; ansic: 43
file content (107 lines) | stat: -rw-r--r-- 2,230 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# ------------------------------------------------------------------------
# KBall makefile
# By Kronoman
# Copyright (c) 2003, 2004
# Thanks to Schwarzung for the help on making the original makefile system.
# ------------------------------------------------------------------------

# This has the target platform defined, this is modified by fix.bat or fix.sh
include target.os

# Suggested by GNU Coding Stardards
SHELL = /bin/sh

# ===============================================
# Target binary name without extension
BINARY = kball

# Source directory
SRCDIR = src

# Include directory
INCDIR = include

# Source code suffix (.c, .cpp, etc)
SRCSUF = .cpp

# Simple source code test file (must be in same dir as makefile for now) :(
# The extension will be taken from SRCSUF, don't put it!
TESTFILE = test
# ===============================================


# -----------------------------
# -- Platform specific stuff --
# -----------------------------

# ------------------
# DJGPP target
# ------------------
ifeq ($(TARGET),DJGPP)

PLATFORMDIR=djgpp

# compiler to invoque
GCC = gxx

# Binary file suffix
BINSUF = dos.exe
# object suffix
OBJSUF = .o

# If you need extra link options (like more librarys, add to LFLAGS var)
LFLAGS = -s -laldmb -ldumb -lalleg

# Compiler flags
CFLAGS = -I$(INCDIR) -Wall -O3
endif

# ------------------
# MingW32
# ------------------
ifeq ($(TARGET),MINGW32)

PLATFORMDIR=mingw32

GCC = g++

# Binary file suffix
BINSUF = _w32.exe
OBJSUF = .o

# If you need extra link options (like more librarys, add to LFLAGS var)
LFLAGS = -Wl,--subsystem,windows -s -laldmb -ldumb -lalleg

# Compiler flags
CFLAGS = -I$(INCDIR) -Wall -O3
endif

# ------------------
# Linux
# ------------------
ifeq ($(TARGET),LINUX)

PLATFORMDIR=linux

GCC = g++

# Binary file suffix
BINSUF = _linux.bin
OBJSUF = .o

# If you need extra link options (like more librarys, add to LFLAGS var)
LFLAGS = -s -laldmb -ldumb `allegro-config --libs`

# Compiler flags
CFLAGS = -I$(INCDIR) -Wall -O3
endif

# ---------------------------------
# -- Platform non-specific stuff --
# ---------------------------------

OBJDIR = obj/$(PLATFORMDIR)
BINDIR = bin

# -- The rules for build are in this file --
include makefile.all