alsa.audio: add debug logs
[AROS.git] / workbench / tools / InstallAROS / install.h
blob3f22f1d7dec579f5c3251965ef29fd31c1bf2cd2
1 #include <exec/lists.h>
2 #include <exec/nodes.h>
4 static const char KMsgWelcome[] =
5 MUIX_B"\nWelcome to the AROS Research OS installer.\n\n" MUIX_N
6 "This program allows you to install AROS\n"
7 "on your computer's hard disk or an attached USB drive.\n\n"
8 "Please be aware that the stability of this software\n"
9 "cannot be guaranteed.\n"
10 "It is possible that " MUIX_B "loss of data" MUIX_N " may occur\n"
11 "on any drive in your system, including those\n"
12 "used by other operating systems.\n";
14 static const char KMsgInstallOptions[] =
15 "\nPlease choose your installation options.\n\n";
17 static const char KMsgDestOptions[] =
18 "\nPlease choose where to install AROS.\n\n"
19 "If you are unsure, then use the defaults";
21 static const char KMsgDestVolume[] =
22 "Destination Partition";
24 static const char KMsgWorkVolume[] =
25 "Work Partition";
27 static const char KMsgBeginWithPartition[] =
28 "OK, we are ready to begin.\n\n"
29 "Since you've chosen to format at least one partition,\n"
30 "you will no longer be able to undo changes\n"
31 "after this point.\n\n"
32 "Select Proceed to begin installation.";
34 static const char KMsgBeginWithoutPartition[] =
35 "OK, we are ready to begin...\n\n"
36 "We have collected enough information\n"
37 "to begin installation on this computer.\n\n"
38 "\nSelect Proceed to begin installation.";
40 static const char KMsgPartitionOptions[] =
41 "We will now create AROS partitions on the destination drive.\n\n"
42 "Please select how you would like to proceed.\n";
44 static const char KMsgDestPartition[] =
45 MUIX_B "System Partition:" MUIX_N;
47 static const char KMsgWorkPartition[] =
48 MUIX_B "Work Partition:" MUIX_N;
50 static const char KMsgPartitionTooBig[] =
51 "The partition sizes you have requested are too large.\n"
52 "The maximum size of an SFS partition is %ld GB (%ld MB),\n"
53 "while the maximum size of an FFS partition is %ld GB (%ld MB).\n"
54 "Please reduce the size of the affected partitions.\n";
56 static const char KMsgGrubOptions[] =
57 "AROS uses the GRUB bootloader.\n\n"
58 "In most cases, GRUB's bootblock should\n"
59 "be installed on the first drive in your system.\n"
60 "If the Installer detects a Microsoft Windows installation,\n"
61 "it will be included as a choice in GRUB's boot menu.\n";
63 static const char KMsgGrubDrive[] =
64 "Drive to install GRUB's bootblock on:";
66 static const char KMsgGrubGOptions[] =
67 MUIX_B "GRUB Settings" MUIX_N;
69 static const char KMsgGrubGrub[] =
70 "Path to GRUB files:";
72 static const char KMsgNoGrubDevice[] =
73 "Please enter the device name and unit number for\n"
74 "the drive GRUB's bootblock should be installed on.\n";
76 static const char KMsgPartitioning[] =
77 "Partitioning your drives...\n\n";
79 static const char KMsgInstall[] =
80 "Copying files to the destination drive.\n\n"
81 "This may take some time...\n";
83 static const char KMsgBootLoader[] =
84 "Copying the GRUB bootloader to your\n"
85 "destination drive, and installing...\n";
87 static const char KMsgPostInstall[] =
88 "Running the external post-install\n"
89 "script. Please wait.\n";
91 static const char KMsgDoneReboot[] =
92 "AROS partitions have now been created!\n"
93 "To continue installation, you must\n"
94 "reboot AROS, and re-run\n"
95 "this installer application\n\n"
96 "Select Proceed to finish\n";
98 static const char KMsgDoneUSB[] =
99 "AROS partitions have now been created!\n"
100 "To continue installation, you must remove\n"
101 "and re-attach your USB drive, and re-run\n"
102 "this installer application\n\n"
103 "Select Proceed to finish\n";
105 static const char KMsgDone[] =
106 "Congratulations, you now have AROS installed!\n\n"
107 "To boot AROS from the destination drive,\n"
108 "remove the installation media and\n"
109 "restart your computer using the\n"
110 "power switch or reset button.\n\n"
111 "Select Proceed to finish\n";
113 static const char KMsgCancelOK[] =
114 "Are you sure you wish to cancel\n"
115 "this installation?\n";
117 static const char KMsgCancelDanger[] =
118 "Irreversible changes have been made\n"
119 "to your system.\n\n"
120 "Cancelling now may leave your PC in an\n"
121 "unbootable state\n\n"
122 "Are you sure you wish to cancel\n"
123 "this installation?\n";
125 static const char KMsgProceed[] =
126 "_Proceed";
128 static const char KMsgNotAllFilesCopied[] =
129 "Not all files in '%s'\n"
130 "were copied.\n"
131 "Should the installation continue?\n";
133 static const char KMsgPartitioningFailed[] =
134 "Partitioning of disk failed. InstallAROS\n"
135 "will now quit.";
137 static const char KMsgGRUBNonFFSWarning[] =
138 "You have selected a filesystem different\n"
139 "than FFS-Intl for the system partition. Since\n"
140 "this distribution of AROS is compiled with the\n"
141 "original GRUB bootloader, you will not be able to\n"
142 "boot the system after installation.\n\n"
143 "Should the partitioning continue?\n";
145 /* Unused strings. Kept for reference */
149 static const char KMsgLanguage[] =
150 "The system prefs for your language settings\n"
151 "will now launch\n\n"
152 "Choose the settings that are relevant to you\n";
154 static const char KMsgNoDrives[] =
155 "It appears you do not have a hard\n"
156 "drive installed in your PC.\n\n"
157 "Installation of AROS can only be performed on to\n"
158 "a hard drive just now. Sorry.\n\nPress Proceed To Exit\n";
162 #define MUIM_IC_NextStep (0x00335551)
163 #define MUIM_IC_PrevStep (0x00335552)
164 #define MUIM_IC_UndoSteps (0x00335553)
166 #define MUIM_IC_Install (0x00335554)
168 #define MUIM_FindDrives (0x00335555)
169 #define MUIM_PartitionFree (0x00335556)
170 #define MUIM_Partition (0x00335557)
171 #define MUIM_Format (0x00335558)
173 #define MUIM_IC_CopyFiles (0x0033555a)
174 #define MUIM_IC_CopyFile (0x0033555b)
176 #define MUIM_IC_CancelInstall (0x0033556a)
177 #define MUIM_IC_ContinueInstall (0x0033556b)
178 #define MUIM_IC_QuitInstall (0x0033556c)
180 #define MUIM_Reboot (0x0033556d)
181 #define MUIM_RefreshWindow (0x00335570)
183 /* to be made obsolete */
185 #define MUIA_Page (0x00335580)
187 #define MUIA_PartitionButton (0x00335581)
188 #define MUIA_Gauge1 (0x00335582)
189 #define MUIA_Gauge2 (0x00335583)
190 #define MUIA_Install (0x00335584)
191 /**/
192 #define MUIA_WelcomeMsg (0x0033558a)
193 #define MUIA_FinishedMsg (0x0033558b)
195 /* new - some/most will "vanish(tm)" */
197 #define MUIA_OBJ_Installer (0x0033558d)
198 #define MUIA_Grub_Options (0x0033558e)
199 #define MUIA_List_Options (0x0033558f)
201 #define MUIA_OBJ_Window (0x00335590)
202 #define MUIA_OBJ_WindowContent (0x00335591)
204 #define MUIA_OBJ_PageTitle (0x00335592)
205 #define MUIA_OBJ_PageHeader (0x00335593)
206 #define MUIA_OBJ_CActionStrng (0x00335594)
208 #define MUIA_OBJ_Back (0x00335595)
209 #define MUIA_OBJ_Proceed (0x00335596)
210 #define MUIA_OBJ_Cancel (0x00335597)
212 #define MUIA_IC_License_File (0x00335598)
213 #define MUIA_IC_License_Mandatory (0x00335599)
215 #define MUIA_IC_EnableUndo (0x00335599)
217 /* Install Results */
219 #define MUIA_InstallComplete (0x003355ff)
220 #define MUIA_InstallFailed (0x003355fe)
222 #define MUIV_Inst_Completed (0xff)
223 #define MUIV_Inst_InProgress (0x00)
224 #define MUIV_Inst_Cancelled (0x01)
225 #define MUIV_Inst_Failed (0x10)
227 struct MUIP_CopyFiles
229 STACKED ULONG MethodID;
230 STACKED CONST_STRPTR srcDir;
231 STACKED CONST_STRPTR dstDir;
232 STACKED CONST_STRPTR fileMask;
233 STACKED ULONG recursive;
236 struct MUIP_CopyFile
238 STACKED ULONG MethodID;
239 STACKED CONST_STRPTR srcFile;
240 STACKED CONST_STRPTR dstFile;
243 enum EStage
245 EMessageStage,
246 ELicenseStage,
247 EPartitionOptionsStage,
248 EInstallOptionsStage,
249 EDestOptionsStage,
250 EGrubOptionsStage,
251 EInstallMessageStage,
252 EPartitioningStage,
253 EInstallStage,
254 EDoneStage
257 struct Install_Options
259 Object *opt_license;
260 Object *opt_lic_box;
261 Object *opt_lic_mgrp;
262 Object *opt_partmethod;
263 Object *opt_format;
264 Object *opt_locale;
265 Object *opt_copycore;
266 Object *opt_copyextra;
267 Object *opt_development;
268 Object *opt_bootloader;
270 Object *opt_reboot;
272 BOOL partitioned;
273 BOOL bootloaded;
276 struct Grub_Options
278 Object *gopt_drive;
279 Object *gopt_grub;
280 Object *gopt_grub2mode;
281 BOOL bootinfo;
284 struct InstallC_UndoRecord
286 struct Node undo_Node; /* Inherits from struct Node */
287 ULONG undo_method;
288 char *undo_src;
289 char *undo_dst;
292 struct optionstmp
294 IPTR opt_format;
295 IPTR opt_locale;
296 IPTR opt_copycore;
297 IPTR opt_copyextra;
298 IPTR opt_development;
299 IPTR opt_bootloader;
300 IPTR opt_reboot;
303 enum IO_OVERWRITE_FLAGS
305 IIO_Overwrite_Ask,
306 IIO_Overwrite_Always,
307 IIO_Overwrite_Never
310 struct Install_DATA
312 Object *partition;
313 Object *page;
314 Object *gauge1;
315 Object *gauge2;
316 Object *label;
317 /**/
318 Object *installer;
320 Object *welcomeMsg;
321 Object *doneMsg;
323 /**/
324 Object *window;
325 Object *contents;
327 Object *pagetitle;
328 Object *pageheader;
329 Object *actioncurrent;
331 Object *back;
332 Object *proceed;
333 Object *cancel;
335 /**/
336 ULONG inst_success;
338 ULONG disable_back,
339 status_back,
340 status_proceed,
341 status_cancel;
343 ULONG cur_width,
344 cur_height;
346 char *instc_lic_file;
347 APTR instc_lic_buffer;
349 struct List instc_undorecord;
351 /** Option Related **/
353 struct Install_Options *instc_options_main;
354 struct Grub_Options *instc_options_grub;
355 struct optionstmp *instc_options_backup;
356 enum EStage instc_stage_prev;
357 enum EStage instc_stage_next;
359 enum IO_OVERWRITE_FLAGS IO_Always_overwrite;
361 BOOL instc_cflag_driveset;
362 BOOL instc_copt_undoenabled;
363 BOOL instc_copt_licensemandatory;
366 #define GRUB1 1
367 #define GRUB2 2
368 /* TODO: add more bootloaders */
370 struct BootloaderData
372 UBYTE type;
373 STRPTR file;