147 lines
4.4 KiB
Makefile
147 lines
4.4 KiB
Makefile
|
##########################################################################
|
||
|
# Makefile for GLFW on DOS using DJGPP.
|
||
|
#-------------------------------------------------------------------------
|
||
|
# To compile GLFW using this makefile, run:
|
||
|
# make -f Makefile.dos.djgpp
|
||
|
# NOTE: You need long filename support (e.g. compile under Windows9x or
|
||
|
# use a LFN driver such as DOSLFN)
|
||
|
##########################################################################
|
||
|
|
||
|
##########################################################################
|
||
|
# Default: Build static library version of GLFW
|
||
|
##########################################################################
|
||
|
default: libglfw.a
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# GLFW version
|
||
|
##########################################################################
|
||
|
VERMAJOR = 2
|
||
|
VERMINOR = 4
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# Compiler settings
|
||
|
##########################################################################
|
||
|
CC = gcc
|
||
|
CFLAGS = -c -I. -I.. -Wall -Os
|
||
|
|
||
|
# Some modules should be optimized for speed (e.g. image decoding)
|
||
|
CFLAGS_SPEED = -c -I. -I.. -Wall -O3 -ffast-math
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# Library builder settings
|
||
|
##########################################################################
|
||
|
MKLIB = ar
|
||
|
LIBFLAGS = -rcs
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# Object files which are part of the GLFW library
|
||
|
##########################################################################
|
||
|
OBJS = \
|
||
|
enable.o \
|
||
|
fullscreen.o \
|
||
|
glext.o \
|
||
|
image.o \
|
||
|
init.o \
|
||
|
input.o \
|
||
|
joystick.o \
|
||
|
tga.o \
|
||
|
thread.o \
|
||
|
time.o \
|
||
|
window.o \
|
||
|
dos_enable.o \
|
||
|
dos_events.o \
|
||
|
dos_fullscreen.o \
|
||
|
dos_glext.o \
|
||
|
dos_init.o \
|
||
|
dos_irq.o \
|
||
|
dos_joystick.o \
|
||
|
dos_keyboard.o \
|
||
|
dos_mouse.o \
|
||
|
dos_thread.o \
|
||
|
dos_time.o \
|
||
|
dos_window.o
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# Rule for building library
|
||
|
##########################################################################
|
||
|
libglfw.a: $(OBJS)
|
||
|
$(MKLIB) $(LIBFLAGS) $@ $(OBJS)
|
||
|
|
||
|
|
||
|
##########################################################################
|
||
|
# Rules for building library object files
|
||
|
##########################################################################
|
||
|
enable.o: ..\\enable.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\enable.c
|
||
|
|
||
|
fullscreen.o: ..\\fullscreen.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\fullscreen.c
|
||
|
|
||
|
glext.o: ..\\glext.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\glext.c
|
||
|
|
||
|
image.o: ..\\image.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS_SPEED) -o $@ ..\\image.c
|
||
|
|
||
|
init.o: ..\\init.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\init.c
|
||
|
|
||
|
input.o: ..\\input.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\input.c
|
||
|
|
||
|
joystick.o: ..\\joystick.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\joystick.c
|
||
|
|
||
|
tga.o: ..\\tga.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS_SPEED) -o $@ ..\\tga.c
|
||
|
|
||
|
thread.o: ..\\thread.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\thread.c
|
||
|
|
||
|
time.o: ..\\time.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\time.c
|
||
|
|
||
|
window.o: ..\\window.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ ..\\window.c
|
||
|
|
||
|
dos_enable.o: dos_enable.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_enable.c
|
||
|
|
||
|
dos_events.o: dos_events.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_events.c
|
||
|
|
||
|
dos_fullscreen.o: dos_fullscreen.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_fullscreen.c
|
||
|
|
||
|
dos_glext.o: dos_glext.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_glext.c
|
||
|
|
||
|
dos_init.o: dos_init.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_init.c
|
||
|
|
||
|
dos_irq.o: dos_irq.s ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -x assembler-with-cpp -o $@ dos_irq.s
|
||
|
|
||
|
dos_joystick.o: dos_joystick.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_joystick.c
|
||
|
|
||
|
dos_keyboard.o: dos_keyboard.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_keyboard.c
|
||
|
|
||
|
dos_mouse.o: dos_mouse.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_mouse.c
|
||
|
|
||
|
dos_thread.o: dos_thread.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_thread.c
|
||
|
|
||
|
dos_time.o: dos_time.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_time.c
|
||
|
|
||
|
dos_window.o: dos_window.c ..\\internal.h platform.h
|
||
|
$(CC) $(CFLAGS) -o $@ dos_window.c
|