3 # Copyright (C) 1999, 2000, 2001 Brian Palmer <brianp@sginet.com>
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 # Windows is default host environment
22 HOST
= mingw32-windows
26 # Choose various options
28 ifeq ($(HOST
),mingw32-linux
)
41 NFLAGS
= -fwin32
-dwin32
42 BIN2C
= ..
$(SEP
)tools
$(SEP
)bin2c
43 TOOLSDIR
= ..
$(SEP
)tools
44 BOOTCD_DIR
= ..
$(SEP
)..
$(SEP
)bootcd
48 all: $(BIN2C
) dosmbr.bin fat.bin fat32.bin isoboot.bin ext2.bin
52 @
$(MAKE
) --no-print-directory
-C
$(TOOLSDIR
)
54 dosmbr.bin
: dosmbr.asm
55 @echo
===================================================== Assembling dosmbr
56 @
$(NASM_CMD
) $(NFLAGS
) -o dosmbr.bin
-f bin dosmbr.asm
58 fat.bin
: fat.asm
$(BIN2C
)
59 @echo
===================================================== Assembling fat
60 @
$(NASM_CMD
) $(NFLAGS
) -o fat.bin
-f bin fat.asm
61 @
$(BIN2C
) fat.bin fat.h fat_data
64 fat32.bin
: fat32.asm
$(BIN2C
)
65 @echo
===================================================== Assembling fat32
66 @
$(NASM_CMD
) $(NFLAGS
) -o fat32.bin
-f bin fat32.asm
67 @
$(BIN2C
) fat32.bin fat32.h fat32_data
69 isoboot.bin
: isoboot.asm
70 @echo
===================================================== Assembling isoboot
71 @
$(NASM_CMD
) $(NFLAGS
) -o isoboot.bin
-f bin isoboot.asm
74 @echo
===================================================== Assembling ext2
75 @
$(NASM_CMD
) $(NFLAGS
) -o ext2.bin
-f bin ext2.asm
76 @
$(BIN2C
) ext2.bin ext2.h ext2_data
80 bootcd
: bootcd_dirs isoboot.bin
81 $(CP
) isoboot.bin
$(BOOTCD_DIR
)
82 $(CP
) dosmbr.bin
$(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
83 $(CP
) ext2.bin
$(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
84 $(CP
) fat.bin
$(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
85 $(CP
) fat32.bin
$(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
86 $(CP
) isoboot.bin
$(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
90 $(MKDIR
) $(BOOTCD_DIR
)
91 $(MKDIR
) $(BOOTCD_DIR
)$(SEP
)disk
92 $(MKDIR
) $(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)reactos
93 $(MKDIR
) $(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)install
94 $(MKDIR
) $(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)bootdisk
95 $(MKDIR
) $(BOOTCD_DIR
)$(SEP
)disk
$(SEP
)loader
100 @echo Clean ALL done.