| 1 | # $Id: Makefile.kmk 2858 2016-09-01 15:12:24Z bird $
|
|---|
| 2 | ## @file
|
|---|
| 3 | # Sub-makefile for kWorker.
|
|---|
| 4 | #
|
|---|
| 5 |
|
|---|
| 6 | #
|
|---|
| 7 | # Copyright (c) 2016 knut st. osmundsen <bird-kBuild-spamx@anduin.net>
|
|---|
| 8 | #
|
|---|
| 9 | # This file is part of kBuild.
|
|---|
| 10 | #
|
|---|
| 11 | # kBuild is free software; you can redistribute it and/or modify
|
|---|
| 12 | # it under the terms of the GNU General Public License as published by
|
|---|
| 13 | # the Free Software Foundation; either version 3 of the License, or
|
|---|
| 14 | # (at your option) any later version.
|
|---|
| 15 | #
|
|---|
| 16 | # kBuild is distributed in the hope that it will be useful,
|
|---|
| 17 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|---|
| 18 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|---|
| 19 | # GNU General Public License for more details.
|
|---|
| 20 | #
|
|---|
| 21 | # You should have received a copy of the GNU General Public License
|
|---|
| 22 | # along with kBuild. If not, see <http://www.gnu.org/licenses/>
|
|---|
| 23 | #
|
|---|
| 24 | #
|
|---|
| 25 |
|
|---|
| 26 |
|
|---|
| 27 | SUB_DEPTH = ../..
|
|---|
| 28 | include $(PATH_KBUILD)/subheader.kmk
|
|---|
| 29 |
|
|---|
| 30 |
|
|---|
| 31 | PROGRAMS += kWorker
|
|---|
| 32 | kWorker_TEMPLATE = BIN-STATIC-THREADED
|
|---|
| 33 | kWorker_DEFS.debug = K_STRICT
|
|---|
| 34 | kWorker_DEFS.release = NASSERT
|
|---|
| 35 | kWorker_SOURCES = kWorker.c
|
|---|
| 36 | kWorker_LIBS = \
|
|---|
| 37 | $(kStuff_1_TARGET) \
|
|---|
| 38 | $(kWorkerLib_1_TARGET)
|
|---|
| 39 | include $(KBUILD_PATH)/sdks/WINDDK71.kmk
|
|---|
| 40 | kWorker_LIBS.win = \
|
|---|
| 41 | $(TEMPLATE_BIN-STATIC-THREADED_LIBS) \
|
|---|
| 42 | $(PATH_SDK_WINDDK71_LIB_WNET)/ntdll.lib
|
|---|
| 43 | kWorker_LDFLAGS.win = \
|
|---|
| 44 | /BASE:0x10000 /DYNAMICBASE:NO /FIXED /SECTION:DefLdBuf,EWR
|
|---|
| 45 |
|
|---|
| 46 |
|
|---|
| 47 | #
|
|---|
| 48 | # Stuff from ../libs. Need to rebuilt it with static CRT.
|
|---|
| 49 | #
|
|---|
| 50 | LIBRARIES += kWorkerLib
|
|---|
| 51 | kWorkerLib_TEMPLATE = LIB-STATIC-THREADED
|
|---|
| 52 | kWorkerLib_DEFPATH = ../lib # Need fix from r2837.
|
|---|
| 53 | kWorkerLib_DEFPATH := $(PATH_SUB_CURRENT)/../lib
|
|---|
| 54 | kWorkerLib_SOURCES = \
|
|---|
| 55 | crc32.c \
|
|---|
| 56 | md5.c \
|
|---|
| 57 | kbuild_version.c
|
|---|
| 58 | kWorkerLib_SOURCES.win = \
|
|---|
| 59 | nt_fullpath.c \
|
|---|
| 60 | quoted_spawn.c \
|
|---|
| 61 | nt/nthlpcore.c \
|
|---|
| 62 | nt/nthlpfs.c \
|
|---|
| 63 | nt/ntdir.c \
|
|---|
| 64 | nt/ntstat.c \
|
|---|
| 65 | nt/ntunlink.c \
|
|---|
| 66 | nt/kFsCache.c
|
|---|
| 67 | kbuild_version.c_DEFS = KBUILD_SVN_REV=$(KBUILD_SVN_REV)
|
|---|
| 68 |
|
|---|
| 69 | #
|
|---|
| 70 | # kStuff library.
|
|---|
| 71 | #
|
|---|
| 72 | LIBRARIES += kStuff
|
|---|
| 73 | kStuff_TEMPLATE = LIB-STATIC-THREADED
|
|---|
| 74 | kStuff_DEFS.debug = K_STRICT
|
|---|
| 75 | kStuff_INCS = kStuff/include
|
|---|
| 76 | kStuff_DEFPATH = $(PATH_ROOT)/src/lib
|
|---|
| 77 |
|
|---|
| 78 | # kLdr
|
|---|
| 79 | kStuff_SOURCES += \
|
|---|
| 80 | kStuff/kLdr/kLdr.c \
|
|---|
| 81 | kStuff/kLdr/kLdrDyld.c \
|
|---|
| 82 | kStuff/kLdr/kLdrDyldFind.c \
|
|---|
| 83 | kStuff/kLdr/kLdrDyldMod.c \
|
|---|
| 84 | kStuff/kLdr/kLdrDyldOS.c \
|
|---|
| 85 | kStuff/kLdr/kLdrDyLdSem.c \
|
|---|
| 86 | kStuff/kLdr/kLdrMod.c \
|
|---|
| 87 | kStuff/kLdr/kLdrModLX.c \
|
|---|
| 88 | kStuff/kLdr/kLdrModMachO.c \
|
|---|
| 89 | kStuff/kLdr/kLdrModNative.c \
|
|---|
| 90 | kStuff/kLdr/kLdrModPE.c
|
|---|
| 91 | kLdr_SOURCES.os2 += \
|
|---|
| 92 | kStuff/kLdr/kLdr-os2.c \
|
|---|
| 93 | kStuff/kLdr/kLdrA-os2.asm
|
|---|
| 94 | kLdr_SOURCES.win += \
|
|---|
| 95 | kStuff/kLdr/kLdr-win.c
|
|---|
| 96 |
|
|---|
| 97 | # kRdr
|
|---|
| 98 | kStuff_SOURCES += \
|
|---|
| 99 | kStuff/kRdr/kRdr.cpp \
|
|---|
| 100 | kStuff/kRdr/kRdrFile.cpp \
|
|---|
| 101 | kStuff/kRdr/kRdrBuffered.cpp
|
|---|
| 102 |
|
|---|
| 103 | # kCpu
|
|---|
| 104 | kStuff_SOURCES += \
|
|---|
| 105 | kStuff/kCpu/kCpuCompare.c \
|
|---|
| 106 | kStuff/kCpu/kCpuGetArchAndCpu.c
|
|---|
| 107 |
|
|---|
| 108 | # kHlp (CRT)
|
|---|
| 109 | kStuff_SOURCES += \
|
|---|
| 110 | kStuff/kHlp/Generic/kHlpMemPComp.c \
|
|---|
| 111 | kStuff/kHlp/Generic/kHlpMemICompAscii.c \
|
|---|
| 112 | kStuff/kHlp/Generic/kHlpStrPCat.c \
|
|---|
| 113 | kStuff/kHlp/Generic/kHlpStrNPCat.c \
|
|---|
| 114 | kStuff/kHlp/Generic/kHlpStrPComp.c \
|
|---|
| 115 | kStuff/kHlp/Generic/kHlpStrNPComp.c \
|
|---|
| 116 | kStuff/kHlp/Generic/kHlpStrICompAscii.c \
|
|---|
| 117 | kStuff/kHlp/Generic/kHlpStrIPCompAscii.c \
|
|---|
| 118 | kStuff/kHlp/Generic/kHlpStrNICompAscii.c \
|
|---|
| 119 | kStuff/kHlp/Generic/kHlpStrNIPCompAscii.c \
|
|---|
| 120 | kStuff/kHlp/Generic/kHlpStrPCopy.c \
|
|---|
| 121 | kStuff/kHlp/Generic/kHlpStrNLen.c \
|
|---|
| 122 | kStuff/kHlp/Generic/kHlpInt2Ascii.c \
|
|---|
| 123 | \
|
|---|
| 124 | kStuff/kHlp/Generic/kHlpGetEnvUZ.c \
|
|---|
| 125 | \
|
|---|
| 126 | kStuff/kHlp/Generic/kHlpGetExt.c \
|
|---|
| 127 | kStuff/kHlp/Generic/kHlpGetFilename.c \
|
|---|
| 128 | kStuff/kHlp/Generic/kHlpIsFilenameOnly.c \
|
|---|
| 129 | \
|
|---|
| 130 | kStuff/kHlp/Generic/kHlpPage.c \
|
|---|
| 131 | \
|
|---|
| 132 | kStuff/kHlp/CRT/kHlpCRTAlloc.cpp \
|
|---|
| 133 | kStuff/kHlp/CRT/kHlpCRTEnv.cpp \
|
|---|
| 134 | kStuff/kHlp/CRT/kHlpCRTString.cpp
|
|---|
| 135 | kStuff_SOURCES.darwin += \
|
|---|
| 136 | kStuff/kHlp/Bare/kHlpSys-darwin.c
|
|---|
| 137 |
|
|---|
| 138 |
|
|---|
| 139 |
|
|---|
| 140 | include $(KBUILD_PATH)/subfooter.kmk
|
|---|
| 141 |
|
|---|