Ignore:
Timestamp:
Nov 19, 2000, 10:27:40 AM (25 years ago)
Author:
bird
Message:

New makefile style.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/opengl/glide/cvg/makefile

    r3864 r4624  
    1 # $Id: makefile,v 1.10 2000-07-19 19:05:13 sandervl Exp $
     1# $Id: makefile,v 1.11 2000-11-19 08:58:10 bird Exp $
    22
    33#
     
    77#
    88
     9
     10#
    911# Directory macros.
     12#
    1013PDWIN32_INCLUDE = ..\..\..\..\include
    1114PDWIN32_LIB     = ..\..\..\..\lib
    12 PDWIN32_BIN     = ..\..\..\..\$(OBJDIR)
     15PDWIN32_BIN     = ..\..\..\..\$(OBJDIR)\Glide\Voodoo2
    1316PDWIN32_TOOLS   = ..\..\..\..\tools\bin
    1417
    1518
    16 # Have extra clean rule.
    17 CLEAN2 = 1
     19#
     20# Tell buildenvironment that we should not copy this into /bin.
     21#
     22NO_MAIN_BIN_COPY = 1
    1823
    1924
     25#
    2026# Compiler, tools, and interference rules.
     27#
    2128!include $(PDWIN32_INCLUDE)/pdwin32.mk
    2229
    2330
    24 # Flag overloads and local macros.
    25 CLEANEXTRAS = rsrc.asm
     31#
     32# Subdirectories to travers.
     33#
     34SUBDIRS = \
     35.\..\swlibs\pcilib \
     36.\init \
     37.\glide \
     38.\texus
    2639
    2740
    28 # Object files. All objects should be prefixed with $(OBJDIR)!
     41#
     42# Object files. Prefix with OBJDIR and one space before the '\'.
     43#
    2944OBJS = \
    3045$(OBJDIR)\initterm.obj
    3146
    3247
     48#
     49# Libraries. One space before the '\'.
     50#
     51LIBS = \
     52..\swlibs\pcilib\$(OBJDIR)\pcilib.lib \
     53texus\$(OBJDIR)/texus.lib \
     54init\$(OBJDIR)/init.lib \
     55glide\$(OBJDIR)/glide.lib \
     56$(PDWIN32_LIB)/kernel32.lib \
     57$(PDWIN32_LIB)/$(ODINCRT).lib \
     58os2386.lib \
     59$(RTLLIB_O)
     60
     61
     62#
    3363# Target name - name of the dll without extention and path.
     64#
    3465TARGET = glide2x
    3566
    3667
    37 # All rule - build objs, target dll, copies dll to bin and makes libs.
    38 all:    $(OBJDIR) \
    39         $(OBJDIR)\$(TARGET).dll \
    40         $(PDWIN32_BIN)\Glide\Voodoo2\$(TARGET).dll \
    41         lib
    42 
    43 
    44 # Lib rule - build importlibrary (and evt. other libs)
    45 lib: $(TARGET).lib $(PDWIN32_LIB)\$(TARGET).lib
    46 
    47 
    48 
    49 # Libs rule - Make (sub) libraries. (Not import libraries!)
    50 libs:
    51     cd ..\swlibs\pcilib
    52     $(MAKE_CMD) $@
    53     cd ..\..\cvg\init
    54     $(MAKE_CMD) $@
    55     cd ..\glide
    56     $(MAKE_CMD) $@
    57     cd ..\texus
    58     $(MAKE_CMD) $@
    59     cd ..
    60 
    61 
    62 # Dll rule - builds the target dll.
    63 $(OBJDIR)\$(TARGET).dll: $(OBJS) libs $(TARGET).def $(OBJDIR)\$(TARGET).lrf
    64     $(LD2) $(LD2FLAGS) @$(OBJDIR)\$(TARGET).lrf
    65 
    66 
    67 # Linker file - creates the parameter file passed on to the linker.
    68 $(OBJDIR)\$(TARGET).lrf: makefile
    69     @echo Creating file <<$@
    70 /OUT:$(OBJDIR)\$(TARGET).dll
    71 /MAP:$(OBJDIR)\$(TARGET).map
    72 $(OBJS)
    73 ..\swlibs\pcilib\$(OBJDIR)\pcilib.lib
    74 texus\$(OBJDIR)\texus.lib
    75 init\$(OBJDIR)\init.lib
    76 glide\$(OBJDIR)\glide.lib
    77 $(PDWIN32_LIB)\kernel32.lib
    78 $(PDWIN32_LIB)/$(ODINCRT).lib
    79 OS2386.LIB
    80 $(RTLLIB_O)
    81 $(TARGET).def
    82 <<keep
    83 
    84 
    85 # Copy rule - copies the dll.
    86 $(PDWIN32_BIN)\Glide\Voodoo2\$(TARGET).dll: $(OBJDIR)\$(TARGET).dll
    87     -mkdir $(PDWIN32_BIN)\Glide > nul 2>&1
    88     -mkdir $(PDWIN32_BIN)\Glide\Voodoo2 > nul 2>&1
    89     $(CP) $** $@
    90     $(CP) $** ..\..\..\..\bin\Glide\Voodoo2\$(TARGET).dll
    91 
    92 
    93 # Dep rule - makes depenencies for C, C++ and Asm files.
    94 dep:
    95     $(DEPEND) -I$(PDWIN32_INCLUDE);$(PDWIN32_INCLUDE)\win \
    96         *.c *.cpp *.h *.asm *.inc $(PDWIN32_INCLUDE)\*.h
    97     cd ..\swlibs\pcilib
    98     $(MAKE_CMD) $@
    99     cd ..\..\cvg\init
    100     $(MAKE_CMD) $@
    101     cd ..\glide
    102     $(MAKE_CMD) $@
    103     cd ..\texus
    104     $(MAKE_CMD) $@
    105     cd ..
    106 
    107 
    108 # Extra cleanrule.
    109 clean2:
    110     cd ..\swlibs\pcilib
    111     $(MAKE_CMD) clean
    112     cd ..\..\cvg\glide
    113     $(MAKE_CMD) clean
    114     cd ..\init
    115     $(MAKE_CMD) clean
    116     cd ..\texus
    117     $(MAKE_CMD) clean
    118     cd ..
    119 
    120 
     68#
    12169# Includes the common rules.
     70#
    12271!include $(PDWIN32_INCLUDE)/pdwin32.post
    12372
    124 
    125 
Note: See TracChangeset for help on using the changeset viewer.