| 1 | # $Id: makefile,v 1.25 2000-12-02 23:32:40 bird Exp $
|
|---|
| 2 |
|
|---|
| 3 | #
|
|---|
| 4 | # Odin32 API
|
|---|
| 5 | #
|
|---|
| 6 | # pe2lx.exe makefile
|
|---|
| 7 | #
|
|---|
| 8 |
|
|---|
| 9 |
|
|---|
| 10 | #
|
|---|
| 11 | # Tell buildenvironment that we're making an vio exe and to invoke additional dep rule
|
|---|
| 12 | #
|
|---|
| 13 | VIO=1
|
|---|
| 14 | EXETARGET=1
|
|---|
| 15 | ADDITIONAL_DEP = mydep
|
|---|
| 16 |
|
|---|
| 17 |
|
|---|
| 18 | #
|
|---|
| 19 | # Compiler, tools, and interference rules thru the win32k makefile.inc file.
|
|---|
| 20 | #
|
|---|
| 21 | !include ..\..\..\makefile.inc
|
|---|
| 22 | !include ..\makefile.inc
|
|---|
| 23 |
|
|---|
| 24 |
|
|---|
| 25 | #
|
|---|
| 26 | # Sanity check
|
|---|
| 27 | #
|
|---|
| 28 | !ifndef WIN32KINCLUDE
|
|---|
| 29 | !error "Fatal error! WIN32KINCLUDE is undefined!"
|
|---|
| 30 | !endif
|
|---|
| 31 |
|
|---|
| 32 |
|
|---|
| 33 | #
|
|---|
| 34 | # Tools and Flags Addjustments
|
|---|
| 35 | #
|
|---|
| 36 | CINCLUDES = -I$(WIN32KINCLUDE) $(CINCLUDES)
|
|---|
| 37 | CDEFINES = $(CDEFINES) -DRING3 -DPE2LX
|
|---|
| 38 | !if "$(VAC3)" == "1" || "$(VAC36)" == "1"
|
|---|
| 39 | CFLAGS = $(CFLAGS) -Ge+ -Gm- -Gn- -Ti+ -Rn -Wall+ppt-ppc-inl-cnv-gnr-vft-gen-uni-ext-
|
|---|
| 40 | CXXFLAGS = $(CXXFLAGS) -Ge+ -Gm- -Gn- -Ti+ -Rn -Gx -Wall+ppt-ppc-inl-cnv-gnr-vft-
|
|---|
| 41 | CLISTING = -Fa$(OBJDIR)\$(@B).s
|
|---|
| 42 | COBJOUT = -Fo$(OBJDIR)\$(@B).obj
|
|---|
| 43 | LD2FLAGS = $(LD2FLAGS) /A:16 /Stack:4096
|
|---|
| 44 | !else
|
|---|
| 45 | !error "Compiler is not yet supported."
|
|---|
| 46 | !endif
|
|---|
| 47 |
|
|---|
| 48 |
|
|---|
| 49 | #
|
|---|
| 50 | # Interference rules.
|
|---|
| 51 | #
|
|---|
| 52 | !if "$(VAC3)" == "1" || "$(VAC36)" == "1"
|
|---|
| 53 | {$(WIN32KMISC)}.c.obj:
|
|---|
| 54 | @echo compiling: $(@B).c
|
|---|
| 55 | @$(CC) $(CFLAGS) $(CINCLUDES) $(CDEFINES) -c $(CLISTING) $(COBJOUT) $<
|
|---|
| 56 |
|
|---|
| 57 | {$(WIN32KMISC)}.cpp.obj:
|
|---|
| 58 | @echo compiling: $(@B).cpp
|
|---|
| 59 | @$(CXX) $(CXXFLAGS) $(CINCLUDES) $(CDEFINES) -c $(CLISTING) $(COBJOUT) $<
|
|---|
| 60 |
|
|---|
| 61 | {$(WIN32KLDR)}.cpp.obj:
|
|---|
| 62 | @echo compiling: $(@B).cpp
|
|---|
| 63 | @$(CXX) $(CXXFLAGS) $(CINCLUDES) $(CDEFINES) -c $(CLISTING) $(COBJOUT) $<
|
|---|
| 64 |
|
|---|
| 65 | .cpp{$(OBJDIR)}.obj:
|
|---|
| 66 | @echo compiling: $(@B).cpp
|
|---|
| 67 | @$(CXX) $(CXXFLAGS) $(CINCLUDES) $(CDEFINES) -c $(CLISTING) $(COBJOUT) $<
|
|---|
| 68 | !else
|
|---|
| 69 | !error "Compiler is not yet supported."
|
|---|
| 70 | !endif
|
|---|
| 71 |
|
|---|
| 72 |
|
|---|
| 73 | #
|
|---|
| 74 | # Object files. Prefix with OBJDIR and one space before the '\'.
|
|---|
| 75 | #
|
|---|
| 76 | OBJS =\
|
|---|
| 77 | $(OBJDIR)\pe2lx.obj\
|
|---|
| 78 | $(OBJDIR)\pe2lxmain.obj\
|
|---|
| 79 | $(OBJDIR)\modulebase.obj\
|
|---|
| 80 | $(OBJDIR)\malloc.obj\
|
|---|
| 81 | $(OBJDIR)\smalloc_avl.obj\
|
|---|
| 82 | $(OBJDIR)\avl.obj\
|
|---|
| 83 | $(OBJDIR)\rmalloc_avl.obj\
|
|---|
| 84 | $(OBJDIR)\new.obj\
|
|---|
| 85 | $(OBJDIR)\stricmp.obj\
|
|---|
| 86 | $(OBJDIR)\vprintf.obj
|
|---|
| 87 |
|
|---|
| 88 |
|
|---|
| 89 | #
|
|---|
| 90 | # Libraries. One space before the '\'.
|
|---|
| 91 | #
|
|---|
| 92 | LIBS = \
|
|---|
| 93 | $(RTLLIB_NRE) \
|
|---|
| 94 | os2386.lib
|
|---|
| 95 |
|
|---|
| 96 |
|
|---|
| 97 | #
|
|---|
| 98 | # Target name - name of the exe without extention and path.
|
|---|
| 99 | #
|
|---|
| 100 | TARGET = pe2lx
|
|---|
| 101 |
|
|---|
| 102 |
|
|---|
| 103 | #
|
|---|
| 104 | # Includes the common rules.
|
|---|
| 105 | #
|
|---|
| 106 | !include $(ODIN32_POST_INC)
|
|---|
| 107 |
|
|---|
| 108 |
|
|---|
| 109 | #
|
|---|
| 110 | # Additional dependencies.
|
|---|
| 111 | #
|
|---|
| 112 | mydep:
|
|---|
| 113 | $(DEPEND) @<<
|
|---|
| 114 | -a -o$$(OBJDIR) $(CINCLUDES)
|
|---|
| 115 | $(WIN32KMISC)\*.c*
|
|---|
| 116 | $(WIN32KLDR)\*.c*
|
|---|
| 117 | $(WIN32KINCLUDE)\*.h
|
|---|
| 118 | <<
|
|---|
| 119 |
|
|---|