3 include $(SRCDIR)/config/aros.cfg
5 .PHONY: $(DISTDIR)/aros-pc-i386.img $(DISTDIR)/system-pc-i386.img
7 #MM bootdisk-pc-i386 : AROS \
8 #MM bootdisk-setup-pc-i386 \
9 #MM kernel-link-pc-i386 \
10 #MM bootloader-$(AROS_TARGET_BOOTLOADER)-$(AROS_TARGET_ARCH)-$(AROS_TARGET_CPU)
12 #MM systemdisk-pc-i386 : AROS \
13 #MM systemdisk-setup-pc-i386 \
14 #MM bootloader-$(AROS_TARGET_BOOTLOADER)-$(AROS_TARGET_ARCH)-$(AROS_TARGET_CPU)
20 Libs/iffparse.library \
23 MODULES_DEFAULT := $(SRCDIR)/$(CURDIR)/../modules.default
24 MODULE_BOOTSTRAP := /$(AROS_DIR_ARCH)/bootstrap.gz
25 MODULE_LEGACY := /$(AROS_DIR_ARCH)/aros-legacy.pkg.gz
26 BOOT_FILES := $(MODULE_BOOTSTRAP) $(shell cat $(MODULES_DEFAULT)) \
31 BOOT_TAR_EXECUTABLES := \
32 C/AddBuffers C/AddDataTypes C/Alias C/Ask C/Assign C/Avail C/Break C/CD \
33 C/ChangeTaskPri C/Copy C/Date C/Delete C/Dir C/DiskChange C/Echo C/Else \
34 C/EndCLI C/EndIf C/EndSkip C/Execute C/FailAt C/Fault C/Filenote System/Format \
35 C/Get C/Getenv C/IPrefs C/If C/Info C/Join C/Lab C/List \
36 C/MakeDir C/MakeLink C/Mount C/NewShell C/Path C/Prompt C/Protect C/Quit \
37 C/Reboot C/Relabel C/Rename C/Resident C/Run C/Search C/Set C/SetClock \
38 C/SetDate C/Setenv C/Skip C/Stack C/Status C/Touch C/Type C/Unalias \
39 C/Unset C/Unsetenv C/Version C/Which C/Why C/install-i386-pc \
41 Classes/DataTypes/ascii.datatype \
42 Classes/DataTypes/binary.datatype \
43 Classes/DataTypes/text.datatype \
44 Classes/DataTypes/picture.datatype \
45 Classes/DataTypes/ilbm.datatype \
46 Classes/DataTypes/png.datatype \
47 Classes/Zune/AboutWindow.mcc \
48 Classes/Zune/Calendar.mcc \
49 Classes/Zune/Clock.mcc \
50 Classes/Zune/IconDrawerList.mui \
51 Classes/Zune/IconImage.mcc \
52 Classes/Zune/IconList.mui \
53 Classes/Zune/IconListview.mui \
54 Classes/Zune/IconDrawerList.mui \
55 Classes/Zune/IconVolumeList.mui Classes/Zune/PrefsWindow.mcc \
56 Classes/Zune/PrefsEditor.mcc Classes/Zune/SystemPrefsWindow.mcc \
57 Devs/clipboard.device \
60 Libs/stdc.library Libs/stdcio.library Libs/posixc.library \
61 Libs/png.library Libs/z1.library Libs/uuid.library \
62 Libs/asl.library Libs/commodities.library \
63 Libs/cybergraphics.library \
64 Libs/datatypes.library Libs/diskfont.library Libs/gadtools.library \
65 Libs/icon.library Libs/kms.library Libs/workbench.library \
66 Libs/reqtools.library Libs/muimaster.library Libs/coolimages.library \
69 System/About System/FixFonts \
70 System/Wanderer/Wanderer \
71 System/Wanderer/Tools/DiskInfo \
72 System/Wanderer/Tools/ExecuteCommand \
73 System/Wanderer/Tools/ExecuteStartup \
74 System/Wanderer/Tools/Info System/Wanderer/Tools/WBNewDrawer \
75 System/Wanderer/Tools/WBRename \
89 System/FixFonts.info \
90 System/Wanderer/Wanderer.info \
91 System/Wanderer/Tools/DiskInfo.info \
92 System/Wanderer/Tools/ExecuteCommand.info System/Wanderer/Tools/Info.info \
93 System/Wanderer/Tools/WBNewDrawer.info System/Wanderer/Tools/WBRename.info \
95 Tools/HDToolBox.info \
97 Tools/Debug/Sashimi.info \
102 Devs/DataTypes/ELF Devs/DataTypes/ELF_EXE Devs/DataTypes/ILBM \
103 Devs/DataTypes/FTXT Devs/DOSDrivers/PIPE \
104 Devs/Keymaps Devs/Mountlist \
105 Fonts/fixed/8 Fonts/arial/13 Fonts/ttcourier/14 \
107 Prefs/Env-Archive/hdtoolbox.prefs \
108 Prefs/Env-Archive/SYS/font.prefs Prefs/Env-Archive/SYS/theme.var \
109 Prefs/Env-Archive/SYS/def_Disk.info \
110 Prefs/Env-Archive/SYS/def_Drawer.info \
111 Prefs/Env-Archive/SYS/def_Project.info \
112 Prefs/Env-Archive/SYS/def_RAM.info \
113 Prefs/Env-Archive/SYS/def_Tool.info \
114 Prefs/Presets/Themes/Mason \
115 Prefs/Presets/Themes/$(AROS_GUI_THEME) \
119 BOOT_SRC_DIR := $(AROSDIR)
120 BOOT_DEST_DIR := $(OSGENDIR)/boot/bootdisk
121 SYSTEM_DEST_DIR := $(OSGENDIR)/boot/systemdisk
123 ifeq ($(AROS_TARGET_BOOTLOADER),grub)
124 BOOT_FILES += $(AROS_DIR_ARCH)/grub/stage1
125 BOOT_TAR_MISC += $(AROS_DIR_ARCH)/grub/menu.lst.DH0 $(AROS_DIR_ARCH)/grub/stage2
126 BOOT_EXTRA_FILES += $(BOOT_DEST_DIR)/$(AROS_DIR_ARCH)/grub/stage2
128 $(BOOT_DEST_DIR)/$(AROS_DIR_ARCH)/grub/stage2 $(SYSTEM_DEST_DIR)/$(AROS_DIR_ARCH)/grub/stage2:
129 @$(CP) $(AROSARCHDIR)/grub/stage2_hdisk $@
132 ifeq ($(AROS_TARGET_BOOTLOADER),grub2)
133 BOOT_FILES += $(AROS_DIR_ARCH)/grub/grub.cfg
134 BOOT_TAR_MISC += $(AROS_DIR_ARCH)/grub/grub.cfg
137 BOOT_TAR_FILES := $(BOOT_TAR_EXECUTABLES) $(BOOT_TAR_ICONS) $(BOOT_TAR_MISC)
139 BOOT_DEST_FILES := $(foreach f, $(BOOT_FILES), $(BOOT_DEST_DIR)/$(f))
141 SYSTEM_DEST_FILES := $(foreach f, $(SYSTEM_FILES), $(SYSTEM_DEST_DIR)/$(f))
144 bootdisk-setup-pc-i386 :
145 @$(MKDIR) "$(AROSDIR)/Tools/Boot Disks"
146 -$(RM) $(BOOT_DEST_DIR)
147 %mkdirs_q $(BOOT_DEST_DIR)
148 %mkdirs_q $(BOOT_DEST_DIR)/$(AROS_DIR_ARCH)/grub
149 @$(ECHO) Generating $(SRCDIR)/$(CURDIR)/menu.lst...
151 's#@modules.default@#sed "s\#^\# module \#g" $(MODULES_DEFAULT)#e' \
152 -e 's#@module.bootstrap@#$(MODULE_BOOTSTRAP)#g' \
153 $(SRCDIR)/$(CURDIR)/menu.lst \
154 > $(BOOT_DEST_DIR)/$(AROS_DIR_ARCH)/grub/menu.lst
157 systemdisk-setup-pc-i386 :
158 @$(MKDIR) "$(AROSDIR)/Tools/Boot Disks"
159 -$(RM) $(SYSTEM_DEST_DIR)
160 %mkdirs_q $(SYSTEM_DEST_DIR)
161 %mkdirs_q $(SYSTEM_DEST_DIR)/C
162 %mkdirs_q $(SYSTEM_DEST_DIR)/L
163 %mkdirs_q $(SYSTEM_DEST_DIR)/Libs
164 %mkdirs_q $(SYSTEM_DEST_DIR)/S
166 #MM workbench-boot-pc-i386
167 workbench-boot-pc-i386:
170 bootdisk-pc-i386: $(DISTDIR)/aros-pc-i386.img
171 systemdisk-pc-i386: $(DISTDIR)/system-pc-i386.img
173 .PHONY: bootdisk-pc-i386-quick systemdisk-pc-i386-quick
176 bootdisk-pc-i386-quick : bootdisk-pc-i386
179 systemdisk-pc-i386-quick : systemdisk-pc-i386
181 $(DISTDIR)/aros-pc-i386.img: $(BOOT_DEST_FILES) $(BOOT_EXTRA_FILES) \
182 $(AROSARCHDIR)/bootstrap.gz \
183 $(GENDIR)/$(CURDIR)/install-$(AROS_HOST_ARCH)-$(AROS_HOST_CPU)
184 @$(MKDIR) -p "$(DISTDIR)"
186 $(COPYTOAFS) $@ --name "AROS Boot Floppy" --size floppy1440 $(BOOT_DEST_DIR)
187 $(GENDIR)/$(CURDIR)/install-$(AROS_HOST_ARCH)-$(AROS_HOST_CPU) $@
189 $(DISTDIR)/system-pc-i386.img: $(SYSTEM_DEST_FILES) \
190 $(SYSTEM_DEST_DIR)/AROS.pkg $(SYSTEM_DEST_DIR)/S/Startup-Sequence
191 @$(MKDIR) -p "$(DISTDIR)"
193 $(COPYTOAFS) $@ --name "AROS Live Floppy" --size floppy1440 $(SYSTEM_DEST_DIR)
195 $(SYSTEM_DEST_DIR)/S/Startup-Sequence:
196 @$(CP) $(SRCDIR)/workbench/s/Startup-Sequence.DEMOFLOPPY $@
198 $(GENDIR)/$(CURDIR)/install-$(AROS_HOST_ARCH)-$(AROS_HOST_CPU): $(SRCDIR)/$(CURDIR)/install.c
199 echo $(GENDIR)/$(CURDIR)
200 @$(MKDIR) -p $(GENDIR)/$(CURDIR)
201 @$(HOST_CC) $(HOST_CFLAGS) $(SRCDIR)/$(CURDIR)/install.c -o $(GENDIR)/$(CURDIR)/install-$(AROS_HOST_ARCH)-$(AROS_HOST_CPU)
203 $(SYSTEM_DEST_DIR)/AROS.pkg : $(addprefix $(BOOT_SRC_DIR)/,$(BOOT_TAR_FILES))
204 @$(RM) -rf $(OSGENDIR)/boot/bootdisk.compressed
205 @$(MKDIR) -p $(OSGENDIR)/boot/bootdisk.compressed
206 @$(MKDIR) -p $(OSGENDIR)/boot/bootdisk.compressed/S
207 @$(CP) $(SRCDIR)/workbench/s/Startup-Sequence $(OSGENDIR)/boot/bootdisk.compressed/S/Startup-Sequence
210 cd $(BOOT_SRC_DIR) && \
211 for path in $(BOOT_TAR_EXECUTABLES); do \
212 $(SH) $(SRCDIR)/$(CURDIR)/copypath $$path $(OSGENDIR)/boot/bootdisk.compressed ; \
213 $(TARGET_STRIP) --strip-unneeded -R .note -R .comment $(OSGENDIR)/boot/bootdisk.compressed/$$path ; \
215 for path in $(BOOT_TAR_ICONS); do \
216 $(SH) $(SRCDIR)/$(CURDIR)/copypath $$path $(OSGENDIR)/boot/bootdisk.compressed ; \
218 for path in $(BOOT_TAR_MISC); do \
219 $(SH) $(SRCDIR)/$(CURDIR)/copypath $$path $(OSGENDIR)/boot/bootdisk.compressed ; \
221 cd $(OSGENDIR)/boot/ && \
223 $(SRCDIR)/tools/package/pkg c AROS.pkg bootdisk.compressed && \
224 bzip2 -9 AROS.pkg && \
225 mv -f AROS.pkg.bz2 $(SYSTEM_DEST_DIR)/AROS.pkg \
228 $(BOOT_DEST_DIR)/% : $(BOOT_SRC_DIR)/%
231 $(SYSTEM_DEST_DIR)/% : $(BOOT_SRC_DIR)/%
236 @$(ECHO) "Insert blank floppy-disk in /dev/fd0 and press enter."
238 @$(ECHO) "Writing AROS Boot Image to floppy..."
239 @dd if=$(DISTDIR)/aros-pc-i386.img of=/dev/fd0
243 @$(ECHO) "Insert blank floppy-disk in /dev/fd0 and press enter."
245 @$(ECHO) "Writing AROS System Image to floppy..."
246 @dd if=$(DISTDIR)/system-pc-i386.img of=/dev/fd0
250 @$(ECHO) -n "Copying AROS kernel to /aros/boot directory... "
251 @cp $(AROSARCHDIR)/kernel /aros/boot/kernel-pc-i386