Subversion Repositories Kolibri OS

Rev

Rev 2816 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2817 IgorA 1
# General rule for naming: variables with CAPITALIZED names hold settings,
2
# you can - and are expected - to modify it; variables with lowercase names
3
# are intermediate variables and macroses not to be modified unless you
4
# know what you're doing.
5
 
6
# Define directories for destination, source repository, sources of kernel, sources of programs.
7
BUILD_DIR:=build
8
REPOSITORY:=../..
9
KERNEL:=$(REPOSITORY)/kernel/trunk
10
PROGS:=$(REPOSITORY)/programs
11
 
12
# The main goal: build kolibri.img and kolibri.iso
13
all: $(BUILD_DIR)/kolibri.img $(BUILD_DIR)/kolibri.iso
14
 
15
# Docpak requires some documents; we place them
16
# into 'docs' subdir and communicate with FASM
17
# through environment var DOCDIR.
18
DOCDIR:=docs/
19
export DOCDIR
20
 
21
# Because most programs are written in FASM and have
22
# the common structure of one main .asm file possibly including
23
# several .inc files, we handle this case separately.
24
# Namely, we organize one big list of such programs
25
# (FASM_PROGRAMS, see below) containing name of local binary file,
26
# name of file inside kolibri.img and name of the source file.
27
# This list is maintained by hand, and the rest is done with some macroses...
28
# well, slightly complicated macroses - however, you do not need to
29
# understand them in order to maintain the list.
30
# To add a FASM program with one .asm file, just
31
# add the corresponding item to the list and enjoy
32
# the power of GNU make.
33
 
34
# The list of all FASM programs with one main FASM file.
35
# Every item consists of three parts, separated by ':'.
36
# First part is the real name of binary file in $(BUILD_DIR)
37
# as it should be produced by make.
38
# Second part is the name of a file inside kolibri.img,
39
# usually uppercased version of first part - to save space
40
# for FAT filesystem.
41
# Third part is the name of the source file.
42
# Spaces separate items, so spaces in names should be
43
# represented as '|'.
44
FASM_PROGRAMS:=\
45
 @clip:@CLIP:$(PROGS)/system/clip/trunk/@clip.ASM \
46
 @menu:@MENU:$(PROGS)/system/menu/trunk/menu.asm \
47
 @notify:@NOTIFY:$(PROGS)/system/notify/trunk/@notify.asm \
48
 @panel:@PANEL:$(PROGS)/system/panel/trunk/@PANEL.ASM \
49
 @rb:@RB:$(PROGS)/system/rb/trunk/@RB.ASM \
50
 @ss:@SS:$(PROGS)/system/ss/trunk/@ss.asm\
51
 refrscrn:REFRSCRN:$(PROGS)/system/refrscrn/refrscrn.asm \
52
 asciivju:ASCIIVJU:$(PROGS)/develop/asciivju/trunk/asciivju.asm \
53
 calc:CALC:$(PROGS)/other/calc/trunk/calc.asm \
54
 calendar:CALENDAR:$(PROGS)/system/calendar/trunk/calendar.asm \
55
 commouse:COMMOUSE:$(PROGS)/system/commouse/trunk/commouse.asm \
56
 cpu:CPU:$(PROGS)/system/cpu/trunk/cpu.asm \
57
 cpuid:CPUID:$(PROGS)/system/cpuid/trunk/CPUID.ASM \
58
 desktop:DESKTOP:$(PROGS)/system/desktop/trunk/desktop.asm \
59
 disptest:DISPTEST:$(PROGS)/system/disptest/trunk/disptest.ASM \
60
 docpack:DOCPACK:$(PROGS)/system/docpack/trunk/docpack.asm \
61
 end:END:$(PROGS)/system/end/light/end.asm \
62
 gmon:GMON:$(PROGS)/system/gmon/gmon.asm \
63
 hdd_info:HDD_INFO:$(PROGS)/system/hdd_info/trunk/hdd_info.asm \
64
 icon:ICON:$(PROGS)/system/icon/trunk/icon.asm \
65
 cropflat:CROPFLAT:$(PROGS)/system/cropflat/cropflat.asm \
66
 kbd:KBD:$(PROGS)/system/kbd/trunk/kbd.ASM \
67
 kpack:KPACK:$(PROGS)/other/kpack/trunk/kpack.asm \
68
 launcher:LAUNCHER:$(PROGS)/system/launcher/trunk/launcher.asm \
69
 magnify:MAGNIFY:$(PROGS)/demos/magnify/trunk/magnify.asm \
70
 mgb:MGB:$(PROGS)/system/mgb/trunk/mgb.asm \
71
 mousemul:MOUSEMUL:$(PROGS)/system/mousemul/trunk/mousemul.asm \
72
 madmouse:MADMOUSE:$(PROGS)/other/madmouse/madmouse.asm \
73
 mykey:MYKEY:$(PROGS)/system/MyKey/trunk/MyKey.asm \
74
 pcidev:PCIDEV:$(PROGS)/system/pcidev/trunk/PCIDEV.ASM \
75
 pic4:PIC4:$(PROGS)/media/pic4/trunk/pic4.asm \
76
 rdsave:RDSAVE:$(PROGS)/system/rdsave/trunk/rdsave.asm \
77
 rtfread:RTFREAD:$(PROGS)/other/rtfread/trunk/rtfread.asm \
78
 run:RUN:$(PROGS)/system/run/trunk/run.asm \
79
 scrshoot:SCRSHOOT:$(PROGS)/media/scrshoot/scrshoot.asm \
80
 setup:SETUP:$(PROGS)/system/setup/trunk/setup.asm \
81
 test:TEST:$(PROGS)/system/test/trunk/test.asm \
82
 tinypad:TINYPAD:$(PROGS)/develop/tinypad/trunk/tinypad.asm \
83
 zkey:ZKEY:$(PROGS)/system/zkey/trunk/ZKEY.ASM \
84
 3d/3dcube2:3D/3DCUBE2:$(PROGS)/demos/3dcube2/trunk/3DCUBE2.ASM \
85
 3d/3dsheart:3D/3DSHEART:$(PROGS)/demos/3dsheart/trunk/3dsheart.asm \
86
 3d/3dwav:3D/3DWAV:$(PROGS)/demos/3dwav/trunk/3dwav.asm \
87
 3d/crownscr:3D/CROWNSCR:$(PROGS)/demos/crownscr/trunk/crownscr.asm  \
88
 3d/flatwav:3D/FLATWAV:$(PROGS)/demos/flatwav/trunk/FLATWAV.ASM \
89
 3d/free3d04:3D/FREE3D04:$(PROGS)/demos/free3d04/trunk/free3d04.asm \
90
 3d/view3ds:3D/VIEW3DS:$(PROGS)/demos/3DS/VIEW3DS.ASM \
91
 demos/bcdclk:DEMOS/BCDCLK:$(PROGS)/demos/bcdclk/trunk/bcdclk.asm \
92
 demos/circle:DEMOS/CIRCLE:$(PROGS)/develop/examples/circle/trunk/circle.asm \
93
 demos/colorref:DEMOS/COLORREF:$(PROGS)/demos/colorref/trunk/colorref.asm \
94
 demos/cslide:DEMOS/CSLIDE:$(PROGS)/demos/cslide/trunk/cslide.asm \
95
 demos/eyes:DEMOS/EYES:$(PROGS)/demos/eyes/trunk/eyes.asm \
96
 demos/fire:DEMOS/FIRE:$(PROGS)/demos/fire/trunk/fire.asm \
97
 demos/firework:DEMOS/FIREWORK:$(PROGS)/demos/firework/trunk/firework.asm \
98
 demos/movback:DEMOS/MOVBACK:$(PROGS)/demos/movback/trunk/movback.asm \
99
 demos/plasma:DEMOS/PLASMA:$(PROGS)/demos/plasma/trunk/plasma.asm \
100
 demos/timer:DEMOS/TIMER:$(PROGS)/demos/timer/trunk/timer.asm \
101
 demos/tinyfrac:DEMOS/TINYFRAC:$(PROGS)/demos/tinyfrac/trunk/tinyfrac.asm \
102
 demos/trantest:DEMOS/TRANTEST:$(PROGS)/demos/trantest/trunk/trantest.asm \
103
 demos/tube:DEMOS/TUBE:$(PROGS)/demos/tube/trunk/tube.asm \
104
 demos/unvwater:DEMOS/UNVWATER:$(PROGS)/demos/unvwater/trunk/unvwater.asm \
105
 demos/web:DEMOS/WEB:$(PROGS)/demos/web/trunk/web.asm \
106
 develop/board:DEVELOP/BOARD:$(PROGS)/system/board/trunk/board.asm \
107
 develop/cObj:DEVELOP/cObj:$(PROGS)/develop/cObj/trunk/cObj.asm \
108
 develop/fasm:DEVELOP/FASM:$(PROGS)/develop/fasm/trunk/fasm.asm \
109
 develop/h2d2b:DEVELOP/H2D2B:$(PROGS)/develop/h2d2b/trunk/h2d2b.asm \
110
 develop/heed:DEVELOP/HEED:$(PROGS)/develop/heed/trunk/heed.asm \
111
 develop/ipc:DEVELOP/IPC:$(PROGS)/network/ipc/trunk/ipc.asm \
112
 develop/keyascii:DEVELOP/KEYASCII:$(PROGS)/develop/keyascii/trunk/keyascii.asm \
113
 develop/mtdbg:DEVELOP/MTDBG:$(PROGS)/develop/mtdbg/mtdbg.asm \
114
 develop/scancode:DEVELOP/SCANCODE:$(PROGS)/develop/scancode/trunk/scancode.asm \
115
 develop/t_edit:DEVELOP/T_EDIT:$(PROGS)/other/t_edit/t_edit.asm \
116
 develop/test_gets:DEVELOP/test_gets:$(PROGS)/develop/libraries/console/examples/test_gets.asm \
117
 develop/testcon2:DEVELOP/TESTCON2:$(PROGS)/develop/libraries/console/examples/testcon2.asm \
118
 develop/thread:DEVELOP/THREAD:$(PROGS)/develop/examples/thread/trunk/thread.asm \
119
 develop/info/asm.syn:DEVELOP/INFO/ASM.SYN:$(PROGS)/other/t_edit/info/asm_syn.asm \
120
 develop/info/cpp_kol_cla.syn:DEVELOP/INFO/CPP_KOL_CLA.SYN:$(PROGS)/other/t_edit/info/cpp_kol_cla_syn.asm \
121
 develop/info/cpp_kol_dar.syn:DEVELOP/INFO/CPP_KOL_DAR.SYN:$(PROGS)/other/t_edit/info/cpp_kol_dar_syn.asm \
122
 develop/info/cpp_kol_def.syn:DEVELOP/INFO/CPP_KOL_DEF.SYN:$(PROGS)/other/t_edit/info/cpp_kol_def_syn.asm \
123
 develop/info/default.syn:DEVELOP/INFO/DEFAULT.SYN:$(PROGS)/other/t_edit/info/default_syn.asm \
124
 develop/info/html.syn:DEVELOP/INFO/HTML.SYN:$(PROGS)/other/t_edit/info/html_syn.asm \
125
 develop/info/ini_files.syn:DEVELOP/INFO/INI_FILES.SYN:$(PROGS)/other/t_edit/info/ini_files_syn.asm \
126
 develop/info/win_const.syn:DEVELOP/INFO/WIN_CONST.SYN:$(PROGS)/other/t_edit/info/win_const_syn.asm \
127
 drivers/com_mouse.obj:DRIVERS/COM_MOUSE.OBJ:$(KERNEL)/drivers/com_mouse.asm \
128
 drivers/emu10k1x.obj:DRIVERS/EMU10K1X.OBJ:$(KERNEL)/drivers/emu10k1x.asm \
129
 drivers/fm801.obj:DRIVERS/FM801.OBJ:$(KERNEL)/drivers/fm801.asm \
130
 drivers/infinity.obj:DRIVERS/INFINITY.OBJ:$(KERNEL)/drivers/infinity.asm \
131
 drivers/ps2mouse.obj:DRIVERS/PS2MOUSE.OBJ:$(REPOSITORY)/drivers/mouse/ps2mouse4d/trunk/ps2mouse.asm \
132
 drivers/sb16.obj:DRIVERS/SB16.OBJ:$(KERNEL)/drivers/sb16/sb16.asm \
133
 drivers/sound.obj:DRIVERS/SOUND.OBJ:$(KERNEL)/drivers/sound.asm \
134
 drivers/vt8235.obj:DRIVERS/VT8235.OBJ:$(KERNEL)/drivers/vt823x.asm \
135
 File|Managers/kfar:File|Managers/KFAR:$(PROGS)/fs/kfar/trunk/kfar.asm \
136
 File|Managers/kfm:File|Managers/KFM:$(PROGS)/fs/kfm/trunk/kfm.asm \
137
 File|Managers/opendial:File|Managers/OPENDIAL:$(PROGS)/fs/opendial/opendial.asm \
138
 games/15:GAMES/15:$(PROGS)/games/15/trunk/15.ASM \
139
 games/arcanii:GAMES/ARCANII:$(PROGS)/games/arcanii/trunk/arcanii.asm \
140
 games/freecell:GAMES/FREECELL:$(PROGS)/games/freecell/freecell.asm \
141
 games/gomoku:GAMES/GOMOKU:$(PROGS)/games/gomoku/trunk/gomoku.asm \
142
 games/invaders:GAMES/INVADERS:$(PROGS)/games/invaders/invaders.asm \
143
 games/klavisha:GAMES/KLAVISHA:$(PROGS)/games/klavisha/trunk/klavisha.asm \
144
 games/lines:GAMES/LINES:$(PROGS)/games/lines/lines.asm \
145
 games/mblocks:GAMES/MBLOCKS:$(PROGS)/games/mblocks/trunk/mblocks.asm \
146
 games/msquare:GAMES/MSQUARE:$(PROGS)/games/MSquare/trunk/MSquare.asm \
147
 games/phenix:GAMES/PHENIX:$(PROGS)/games/phenix/trunk/phenix.asm \
148
 games/pipes:GAMES/PIPES:$(PROGS)/games/pipes/pipes.asm \
149
 games/pong:GAMES/PONG:$(PROGS)/games/pong/trunk/pong.asm \
150
 games/pong3:GAMES/PONG3:$(PROGS)/games/pong3/trunk/pong3.asm \
151
 games/rsquare:GAMES/RSQUARE:$(PROGS)/games/rsquare/trunk/rsquare.asm \
152
 games/soko:GAMES/SOKO:$(PROGS)/games/soko/trunk/SOKO.ASM \
153
 games/snake:GAMES/SNAKE:$(PROGS)/games/snake/trunk/snake.asm \
154
 games/sq_game:GAMES/SQ_GAME:$(PROGS)/games/sq_game/trunk/SQ_GAME.ASM \
155
 games/sudoku:GAMES/SUDOKU:$(PROGS)/games/sudoku/trunk/sudoku.asm \
156
 games/sw:GAMES/SW:$(PROGS)/games/sw/trunk/sw.asm \
157
 games/tanks:GAMES/TANKS:$(PROGS)/games/tanks/trunk/tanks.asm \
158
 games/tetris:GAMES/TETRIS:$(PROGS)/games/tetris/trunk/tetris.asm \
159
 lib/archiver.obj:LIB/ARCHIVER.OBJ:$(PROGS)/fs/kfar/trunk/kfar_arc/kfar_arc.asm \
160
 lib/box_lib.obj:LIB/BOX_LIB.OBJ:$(PROGS)/develop/libraries/box_lib/trunk/box_lib.asm \
161
 lib/console.obj:LIB/CONSOLE.OBJ:$(PROGS)/develop/libraries/console/console.asm \
162
 lib/libgfx.obj:LIB/LIBGFX.OBJ:$(PROGS)/develop/libraries/libs-dev/libgfx/libgfx.asm \
163
 lib/libimg.obj:LIB/LIBIMG.OBJ:$(PROGS)/develop/libraries/libs-dev/libimg/libimg.asm \
164
 lib/libini.obj:LIB/LIBINI.OBJ:$(PROGS)/develop/libraries/libs-dev/libini/libini.asm \
165
 lib/libio.obj:LIB/LIBIO.OBJ:$(PROGS)/develop/libraries/libs-dev/libio/libio.asm \
166
 lib/network.obj:LIB/NETWORK.OBJ:$(PROGS)/develop/libraries/network/network.asm \
167
 lib/proc_lib.obj:LIB/PROC_LIB.OBJ:$(PROGS)/develop/libraries/proc_lib/trunk/proc_lib.asm \
168
 lib/cnv_png.obj:LIB/CNV_PNG.OBJ:$(PROGS)/media/zsea/plugins/png/cnv_png.asm \
169
 media/animage:MEDIA/ANIMAGE:$(PROGS)/media/animage/trunk/animage.asm \
170
 media/cdp:MEDIA/CDP:$(PROGS)/media/cdp/trunk/cdp.asm \
171
 media/kiv:MEDIA/KIV:$(PROGS)/media/kiv/trunk/kiv.asm \
172
 media/listplay:MEDIA/LISTPLAY:$(PROGS)/media/listplay/trunk/listplay.asm \
173
 media/midamp:MEDIA/MIDAMP:$(PROGS)/media/midamp/trunk/midamp.asm \
174
 media/startmus:MEDIA/STARTMUS:$(PROGS)/media/startmus/trunk/STARTMUS.ASM \
175
 network/airc:NETWORK/AIRC:$(PROGS)/network/airc/trunk/airc.asm \
176
 network/arpstat:NETWORK/ARPSTAT:$(PROGS)/network/arpstat/trunk/arpstat.asm \
177
 network/chess:NETWORK/CHESS:$(PROGS)/network/chess/trunk/chess.asm \
178
 network/downloader:NETWORK/DOWNLOADER:$(PROGS)/network/downloader/trunk/downloader.asm \
179
 network/ethstat:NETWORK/ETHSTAT:$(PROGS)/network/ethstat/trunk/ethstat.asm \
180
 network/ftps:NETWORK/FTPS:$(PROGS)/network/ftps/trunk/FTPS.ASM \
181
 network/https:NETWORK/HTTPS:$(PROGS)/network/https/trunk/https.asm \
182
 network/nntpc:NETWORK/NNTPC:$(PROGS)/network/nntpc/trunk/nntpc.asm \
183
 network/nslookup:NETWORK/NSLOOKUP:$(PROGS)/develop/libraries/network/examples/nslookup.asm \
184
 network/popc:NETWORK/POPC:$(PROGS)/network/popc/trunk/popc.asm \
185
 network/smtps:NETWORK/SMTPS:$(PROGS)/network/smtps/trunk/smtps.asm \
186
 network/stackcfg:NETWORK/STACKCFG:$(PROGS)/network/stackcfg/trunk/stackcfg.asm \
187
 network/telnet:NETWORK/TELNET:$(PROGS)/network/telnet/trunk/telnet.asm \
188
 network/tftpc:NETWORK/TFTPC:$(PROGS)/network/tftpc/trunk/tftpc.asm \
189
 network/VNCclient:NETWORK/VNCclient:$(PROGS)/network/VNCclient/VNCclient.asm \
190
 network/ym:NETWORK/YM:$(PROGS)/network/ym/trunk/ym.asm \
191
 network/zeroconf:NETWORK/ZEROCONF:$(PROGS)/network/zeroconf/trunk/zeroconf.asm \
192
# end of list
193
# The list of all FASM programs with one main FASM file for CD image.
194
# Format of an item is exactly the same as in the previous list.
195
FASM_PROGRAMS_CD:=\
196
 drivers/atikms:DRIVERS/ATIKMS:$(REPOSITORY)/drivers/video/drm/radeon/atikms.asm \
197
# end of list
198
 
199
# The list of all FASM programs which needs to be compiled without KPACKing.
200
FASM_NOKPACK_PROGRAMS:=\
201
 distr_data/9x2klbr.exe:-:$(PROGS)/hd_load/9x2klbr/9x2klbr.asm \
202
 distr_data/MeOSload.com:-:$(PROGS)/hd_load/meosload/MeOSload.asm \
203
 distr_data/mtldr:-:$(PROGS)/hd_load/mtldr/mtldr.asm \
204
 mtldr_for_installer:-:$(PROGS)/hd_load/mtldr_install/mtldr_code/mtldr.asm \
205
 distr_data/mtldr_install.exe:-:$(PROGS)/hd_load/mtldr_install/mtldr_install.asm \
206
 distr_data/MeOSload_for_usb_boot_old.com:-:$(PROGS)/hd_load/usb_boot_old/MeOSload.asm \
207
 distr_data/enable_for_usb_boot_old.exe:-:$(PROGS)/hd_load/usb_boot_old/enable.asm \
208
 distr_data/BOOT_F32.BIN:-:$(PROGS)/hd_load/usb_boot/BOOT_F32.ASM \
209
 distr_data/MTLD_F32:-:$(PROGS)/hd_load/usb_boot/mtldr.asm \
210
 distr_data/inst.exe:-:$(PROGS)/hd_load/usb_boot/inst.asm \
211
 distr_data/setmbr.exe:-:$(PROGS)/hd_load/usb_boot/setmbr.asm \
212
#end of list
213
 
214
# The list of all NASM programs with one main NASM file.
215
# Format of an item is exactly the same as in the previous list.
216
NASM_PROGRAMS:=\
217
 demos/aclock:DEMOS/ACLOCK:$(PROGS)/demos/aclock/trunk/aclock.asm \
218
 games/c4:GAMES/C4:$(PROGS)/games/c4/trunk/c4.asm \
219
# end of list
220
 
221
# The list of files which should be copied from somewhere.
222
# Format of an item is exactly the same as in the previous list.
223
COPY_FILES:=\
224
 macros.inc:MACROS.INC:$(PROGS)/macros.inc \
225
 config.inc:CONFIG.INC:$(PROGS)/config.inc \
226
 struct.inc:STRUCT.INC:$(PROGS)/struct.inc \
227
 develop/te_icon.png:DEVELOP/TE_ICON.PNG:$(PROGS)/other/t_edit/te_icon.png \
228
 develop/tl_nod_16.png:DEVELOP/TL_NOD_16.PNG:$(PROGS)/other/t_edit/tl_nod_16.png \
229
 develop/tl_sys_16.png:DEVELOP/TL_SYS_16.PNG:$(PROGS)/media/log_el/trunk/tl_sys_16.png \
230
 develop/t_edit.ini:DEVELOP/T_EDIT.INI:$(PROGS)/other/t_edit/t_edit.ini \
231
 File|Managers/z_icons.png:File|Managers/Z_ICONS.PNG:$(PROGS)/fs/opendial/z_icons.png \
232
 File|Managers/kfm_keys.txt:File|Managers/KFM_KEYS.TXT:$(PROGS)/fs/kfm/trunk/docs/english/kfm_keys.txt \
233
 File|Managers/buttons.bmp:File|Managers/BUTTONS.BMP:$(PROGS)/fs/kfm/trunk/buttons.bmp \
234
 File|Managers/icons.bmp:File|Managers/ICONS.BMP:$(PROGS)/fs/kfm/trunk/icons.bmp \
235
 fonts/litt.chr:FONTS/LITT.CHR:$(PROGS)/demos/bgitest/trunk/FONTS/LITT.CHR \