source: proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/vrippack-0.31/src/softrender/bak/makefile @ 37

Last change on this file since 37 was 37, checked in by (none), 14 years ago

Added original make3d

File size: 2.7 KB
Line 
1#!/usr/sbin/make
2
3#
4#  Homan Igehy
5#
6#  Modified by: Brian Curless
7
8#  Computer Graphics Laboratory
9#  Stanford University
10
11#  ---------------------------------------------------------------------
12
13#  Copyright (1997-2001) The Board of Trustees of the Leland Stanford
14#  Junior University. Except for commercial resale, lease, license or
15#  other commercial transactions, permission is hereby given to use,
16#  copy, modify this software for academic purposes only.  No part of
17#  this software or any derivatives thereof may be used in the
18#  production of computer models for resale or for use in a commercial
19#  product. STANFORD MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY
20#  KIND CONCERNING THIS SOFTWARE.  No support is implied or provided.
21
22
23ifndef OPTIMIZER
24        OPTIMIZER = -O
25endif
26
27ROOT = ../..
28
29# Get OS uname
30UNAME := $(shell uname)
31
32ifeq ($(UNAME), IRIX)
33
34        # Set optimizer flags to allow it to run on Indys...
35        ifeq ($(OPTIMIZER), -O)
36            OPTIMIZER = -O -mips3
37        endif  #OPTIMIZER
38
39        CPP = CC
40
41        CCFLAGS = -woff3262
42
43        INCLS = -I. -I$(ROOT)/include
44
45        LIBPATHS = -L. -L$(ROOT)/lib
46
47        LIBS =  -lply -llinear -ltclrl -lreadline -ltermcap \
48                -ltk -ltcl -lsl -lX11 -lc -lm
49
50        ASFLAGS = -mips2 -O2
51
52else
53
54        # Set special optimizer flags...
55        ifeq ($(OPTIMIZER),-O)
56                OPTIMIZER = -O6 -march=i686 -malign-double -fno-for-scope \
57                            -funroll-loops -fomit-frame-pointer -ffast-math
58        endif
59
60        CPP = g++
61
62        CCFLAGS = -DLINUX -Wno-unused
63
64        INCLS = -I. -I$(ROOT)/include
65
66        LIBPATHS = -L. -L$(ROOT)/lib
67
68endif
69
70CCFLAGS := $(INCLS) -DFUNCPROTO -DHAVE_UNISTD_H $(CCFLAGS)
71CPP := $(CPP) $(OPTIMIZER)
72
73SHELL = /bin/sh
74AS = as
75AR = ar
76AWK = awk
77TR2CL = trunc_to_ceil.awk
78
79HACK =  -DInterpolate_$$Interp -DConstant_$$Const \
80        -DSampleCalc_$$Calc    -DFrameBuffer_$$Frame \
81
82
83TRI_OBJS = \
84        sl_triangle_ZI_None_Dda_Intensity.o
85
86TRI_FILES = makefile sl_triangle.C sl_common.H sl_common.I sl_hack.H \
87        sl_vertex.H sl_val.H sl_framebuffer.H sl_framebuffer.I \
88        sl_texture.H sl_texture.I
89
90SL_OBJS = $(TRI_OBJS)
91SL_LIB = libsl.a
92
93default: $(SL_LIB)
94
95all: $(SL_LIB)
96
97install: clobber depend all
98
99$(SL_LIB): makefile $(SL_OBJS)
100        $(AR) ru $@ $(SL_OBJS)
101
102$(TRI_OBJS): $(TRI_FILES)
103        Interp=`echo $@|$(AWK) -F_ '{print $$3}'`;\
104        Const=`echo $@|$(AWK) -F_ '{print $$4}'`;\
105        Calc=`echo $@|$(AWK) -F_ '{print $$5}'`;\
106        Frame=`echo $@|$(AWK) -F_ '{print $$6}'|$(AWK) -F. '{print $$1}'`;\
107        File=`echo $@ | $(AWK) -F_ '{print $$1"_"$$2}'`;\
108        $(CPP) $(HACK) $(CCFLAGS) -c $$File.C -o $@
109
110clean:
111        -/bin/rm -f  *~ *.o *.s *.S core
112
113clobber:
114        -/bin/rm -f *~ *.o *.s *.S makedep core curtest core Makedepend \
115        mon.out libsl.a
116
117depend:
118        echo > makedep
119        gccmakedep -fmakedep -- $(CFLAGS) -- $(CSRCS)
120        -rm makedep.bak
121
122-include makedep
123
124# DO NOT DELETE
Note: See TracBrowser for help on using the repository browser.