1
# Mesa 3-D graphics library
4
# Copyright (C) 1999-2003 Brian Paul All Rights Reserved.
6
# Permission is hereby granted, free of charge, to any person obtaining a
7
# copy of this software and associated documentation files (the "Software"),
8
# to deal in the Software without restriction, including without limitation
9
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
10
# and/or sell copies of the Software, and to permit persons to whom the
11
# Software is furnished to do so, subject to the following conditions:
13
# The above copyright notice and this permission notice shall be included
14
# in all copies or substantial portions of the Software.
16
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
17
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19
# BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
20
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
21
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
# MinGW core makefile v1.4 for Mesa
25
# Copyright (C) 2002 - Daniel Borca
26
# Email : dborca@users.sourceforge.net
27
# Web : http://www.geocities.com/dborca
29
# MinGW core-glut makefile updated for Mesa 7.0
31
# Updated : by Heromyth, on 2007-7-21
32
# Email : zxpmyth@yahoo.com.cn
33
# Bugs : 1) All the default settings work fine. But the setting X86=1 can't work.
34
# The others havn't been tested yet.
35
# 2) The generated DLLs are *not* compatible with the ones built
36
# with the other compilers like VC8, especially for GLUT.
37
# 3) Although more tests are needed, it can be used individually!
43
# Environment variables:
46
# GLIDE path to Glide3 SDK; used with FX.
47
# default = $(TOP)/glide3
48
# FX=1 build for 3dfx Glide3. Note that this disables
49
# compilation of most WMesa code and requires fxMesa.
50
# As a consequence, you'll need the Win32 Glide3
51
# library to build any application.
53
# ICD=1 build the installable client driver interface
54
# (windows opengl driver interface)
56
# X86=1 optimize for x86 (if possible, use MMX, SSE, 3DNow).
61
# clean: remove object files
67
.INTERMEDIATE: x86/gen_matypes.exe
70
# Set this to the prefix of your build tools, i.e. mingw32-
71
TOOLS_PREFIX = mingw32-
88
GLUT_DLL = $(LIB_NAME)$(DLL_EXT)
89
GLUT_IMP = $(LIB_PRE)$(LIB_NAME)$(IMP_EXT)
90
GLUT_DEF = $(LIB_NAME).def
92
LDLIBS = -L$(LIBDIR) -lwinmm -lgdi32 -luser32 -lopengl32 -lglu32
93
LDFLAGS = $(STRIP) -shared -fPIC -Wl,--kill-at
95
CFLAGS += -DBUILD_GLUT32 -DGLUT_BUILDING_LIB -DMESA -D_DLL
96
CFLAGS += -DNDEBUG -DLIBRARYBUILD -I$(TOP)/include
98
CC = $(TOOLS_PREFIX)gcc
99
CXX = $(TOOLS_PREFIX)g++
105
UNLINK = del $(subst /,\,$(1))
106
ifneq ($(wildcard $(addsuffix /rm.exe,$(subst ;, ,$(PATH)))),)
109
ifneq ($(wildcard $(addsuffix /rm,$(subst :, ,$(PATH)))),)
113
HDRS = glutint.h glutstroke.h glutbitmap.h glutwin32.h stroke.h win32_glx.h win32_x11.h
170
SOURCES = $(SRCS) $(SRCSSEMIGENS)
172
OBJECTS = $(addsuffix .o,$(basename $(SOURCES)))
175
$(CC) -o $@ $(CFLAGS) -c $<
177
$(CXX) -o $@ $(CXXFLAGS) -c $<
180
all: $(LIBDIR) $(LIBDIR)/$(GLUT_DLL) $(LIBDIR)/$(GLUT_IMP)
185
$(LIBDIR)/$(GLUT_DLL) $(LIBDIR)/$(GLUT_IMP): $(OBJECTS)
186
$(CXX) $(LDFLAGS) -o $(LIBDIR)/$(GLUT_DLL) $^ $(LDLIBS)
187
$(DLLTOOL) --as=as --dllname $(LIB_NAME) --output-def $(LIBDIR)/$(GLUT_DEF) $^
188
$(DLLTOOL) --as=as -k --dllname $(LIB_NAME) --output-lib $(LIBDIR)/$(GLUT_IMP) --def $(LIBDIR)/$(GLUT_DEF)
b'\\ No newline at end of file'