Commit graph

220 commits

Author SHA1 Message Date
Stanislav Motylkov f851b82570 [USETUP] Update russian translation
Addendum to 03b7e13, 29ace9c and a5bcd95.
2018-12-08 23:36:06 +01:00
Ștefan Fulea b0ab61e6c3
[BOOTDATA][SETUPLIB] Setup the Romanian Stdandard Keyboard layout. (#861)
Adjust the miscellaneous files to activate the Romanian Standard
Keyboard layout in the OS and set it as default for Romanian.

CORE-15056
2018-12-08 18:53:18 +01:00
Hermès Bélusca-Maïto 79bc82206f
[SETUPLIB] Re-enable the filesystem detection code based on recognition by FSDs. 2018-11-25 15:03:52 +01:00
Hermès Bélusca-Maïto 9504a38f52
[SETUPLIB] Dismount a disk partition before deleting it. 2018-11-25 15:03:47 +01:00
Hermès Bélusca-Maïto a31d2f820a
[SETUPLIB] Improve the Freeldr timeout INI setting hack-fix. Dedicated to Mark Jansen ;-) CORE-15193 2018-11-24 02:45:03 +01:00
Hermès Bélusca-Maïto 70fa2e2eb4
[SETUPLIB][USETUP] Additional partition validity checks.
Always perform the partition validity checks when creating new
primary/extended/logical partitions, and also when a new partition
is automatically created when unpartitioned space is selected for
ReactOS installation.

CORE-12246
2018-11-18 21:13:36 +01:00
Hermès Bélusca-Maïto f527e23aa7
[SETUPLIB] Lock the BTRFS volume before installing the new bootsector code.
CORE-15334 CORE-15339

The BTRFS driver requires the volume to be locked in order to modify
the first sectors of the partition, even though they are outside the
file-system space / in the reserved area (they are situated before
the super-block at 0x1000) and is in principle allowed by the NT
storage stack.
So we lock here in order to write the bootsector at sector 0.
If locking fails, we ignore and continue nonetheless.

See also the following links for reference:
https://stackoverflow.com/a/12928934
https://docs.microsoft.com/en-us/windows/desktop/api/fileapi/nf-fileapi-writefile
https://support.microsoft.com/en-us/help/942448/changes-to-the-file-system-and-to-the-storage-stack-to-restrict-direct
2018-11-11 21:55:48 +01:00
Hermès Bélusca-Maïto bfb2b88f82
[SETUPLIB] Use proper file share access when opening partitions for raw access. 2018-11-11 21:47:37 +01:00
Luo Yufan 5cdee1ab82 [TRANSLATION] Update Simplified Chinese translation. (#1028) 2018-11-11 17:57:12 +01:00
Adam Słaboń b8044d6783 [TRANSLATION] Polish translation update (#1029)
Translated missing strings and improved existing translations.
2018-11-11 17:55:01 +01:00
Pierre Schweitzer 26408b02f1
[SETUP] Align partition start at 2048 minimum
This will allow compatibility with modern OSes and
modern disk management utilities.
It will also improve performances by properly aligning
partition start.
And it will let enough room at the begin of the disk
for 3rd party bootloaders.

WARNING: this is not compatible with previous partition
model, and old one will likely not be compatible. You'll
have to erase your whole partition table and start from
scratch.
2018-11-11 17:38:37 +01:00
Luo Yufan 91e032f9b1 [TRANSLATION] Update Simplified Chinese translation. (#1025) 2018-11-09 15:31:53 +01:00
Ercan Ersoy ea47d95b05 [OSK][RAPPS][USETUP] Turkish translations update. (#1024) 2018-11-09 15:13:03 +01:00
Ercan Ersoy bb0de60a4e [USETUP] Fix and add Turkish translation. (#1020) 2018-11-08 13:25:45 +01:00
Hermès Bélusca-Maïto 073c09e491
[USETUP] Display the chosen filesystem name in case of bootcode installation failure.
Simplified implementation of the proposed solution by George Bișoc
and revised by Victor Perevertkin from PR #952.

NOTE: For whatever reason ERROR_INSTALL_BOOTCODE and ERROR_WRITE_BOOT
seem to be redundant with each other. To be investigated...
2018-11-08 01:02:21 +01:00
Bișoc George 4c6370de16 [USETUP] Remove the PARTITION_EXT2 constant and use PARTITION_LINUX in favour since PARTITION_EXT2 is just an alias to PARTITION_LINUX
And since we're here, add PARTITION_LINUX_EXT to ReactOS I/O controls header (rosioctl.h).
2018-11-07 23:16:29 +01:00
Bișoc George 538f9d6aae [USETUP] When choosing BTRFS for the partition, don't think of it as Ext2 but just a Linux partition
Most of Linux filesystems have the MBR ID assigned as 0x83 and when the user chooses BTRFS upon partitions page wizard, we're thinking of the partition as having Ext2 filesystem which is wrong and misleading.
2018-11-07 23:16:29 +01:00
Joann Mõndresku b63e2d5046 [TRANSLATIONS] Style fixes for Estonian 2018-11-07 22:10:27 +01:00
Ercan Ersoy 2e562fd690 [WELCOME] Fix some Turkish translations. 2018-11-07 22:09:17 +01:00
Ercan Ersoy 7c0c3a1bd5 [REACTOS] Fix and add Turkish translations. 2018-11-07 22:09:17 +01:00
Hermès Bélusca-Maïto bbc4bb2d08
[REACTOS] Add features/usability additions.
- Interface the TreeList code and populate it with the list of
  discovered disks and partitions. Code is adapted from USETUP.
  Also display the names of the disks.

- Display some installation settings summary, before doing the
  installation proper.

- Force the user to select a checkbox when (s)he acknowledges that
  ReactOS is alpha-quality software and may break on his/her computer
  or corrupt his/her data.

- Improve wizard pages transitions and buttons enabling/disabling.

- Press Shift-F10 to start a command-line (as in the 2nd-stage setup
  in syssetup.dll).

- Use some explicit UNICODE functions/macros.
2018-11-06 00:09:16 +01:00
Hermès Bélusca-Maïto a531843245
[REACTOS] Add two icons (drive and partition) for the drive list. 2018-11-06 00:09:15 +01:00
Hermès Bélusca-Maïto 6b1e7b182a
[REACTOS] Update translations and add dialog controls for Setup Summary dialog. 2018-11-06 00:09:15 +01:00
Hermès Bélusca-Maïto 2fdfb411b6
[REACTOS] Add a TreeList control (TreeView with columns).
Add the TreeList control from Anton Zechner and Sébastien Kirche
from https://github.com/sebkirche/treelist (under GPL-3.0+) as a
*TEMPORARY* solution until a better-suited control for ReactOS is
developed.

- Compilation fixes for the TreeList control.
2018-11-06 00:09:14 +01:00
Hermès Bélusca-Maïto e282ec39a2
[SETUPLIB] Retrieve and store the machine (architecture) ID of the discovered NTOS installations. Will be used later. 2018-11-06 00:09:13 +01:00
Hermès Bélusca-Maïto f41750ab7f
[SETUPLIB][USETUP] Partition code improvements.
- SETUPLIB and USETUP: Convert PARTENTRY::DriveLetter to WCHAR.

- SETUPLIB: Retrieve volume label.

- SETUPLIB and USETUP: Move the partition types (IDs) table from
  USETUP to SETUPLIB so that they can share it with the 1st-stage
  GUI installer too. Also take the opportunity to update the table
  with information from http://www.win.tue.nl/~aeb/partitions/partition_types-1.html
  and cross-checked with the list from Paragon Hard-Disk Manager.

- USETUP: Simplify PrintPartitionData().
- Add some code comments.
2018-11-06 00:09:02 +01:00
Hermès Bélusca-Maïto 7c3570f9f5
[REACTOS] Add helpers and modify ConvertNtPathToWin32Path() to make it use a cache of NT/Win32 path mappings.
This increases performance for each time the SETUPLIB calls (using NT paths)
Win32 SetupAPI functions which of course only accept Win32 paths.

- Handle also the fact that a NT path to convert may start with
  \Device\HarddiskX\PartitionY\..., which can be a symlink to
  \Device\HarddiskVolumeN\... on some systems. In that case, the
  Win32 path mapping should be done slightly differently.

- Add support for network mapped drives.
2018-11-06 00:04:30 +01:00
Hermès Bélusca-Maïto dd2fe4e126
[REACTOS] Diverse UI improvements.
- Improve UI usage and wizard transitions (Work In Progress).
- Add interfacing code that display installation status.
- When the user attempts to cancel the installation during file copying,
  pause the file copying, and restart it if the user changes it mind and
  wants to continue the installation. Otherwise file copying is properly
  halted.
2018-11-06 00:04:29 +01:00
Hermès Bélusca-Maïto 86f31289ef
[BOOTDATA][SETUPLIB][REACTOS] INF support fixes.
- BOOTDATA: Use standard INF signature string, so that they can be
  opened successfully using ReactOS' or Windows' setupapi.dll with
  the INF_STYLE_WIN4 style.

- SETUPLIB: Use the correct INF_STYLE_* INF styles in SpInfOpenInfFile() calls.

- REACTOS : Switch thread locale to user-specified LocaleId when calling
  SetupOpenInfFileW(), so that the correct localized strings are used.
2018-11-06 00:04:19 +01:00
Hermès Bélusca-Maïto 42758b303b
[SETUPLIB] Fixes and improvements for the file copying code.
- In PrepareCopyInfFile(), explicitly use AddSectionToCopyQueueCab()
  to retrieve the files from the CAB INF.

  Otherwise if one continued to use and rely on AddSectionToCopyQueue()
  to do this job instead, bad things could happen like, re-enumerating
  twice or more (and adding them to the file queue) the same files.
  This is because in the new code AddSectionToCopyQueue() can be called
  many times to deal with different SIF file sections. The old code then
  called AddSectionToCopyQueueCab() in turn, but on the same list...
  Now the steps performed are clear, and everything works as intended.

- Simplify the code that computes the full source and destination paths
  for the files to be copied and directories to be created, using helper
  functions.

- Compute the source file and target location from the TXTSETUP.SIF
  entries in a NT-compatible manner.
2018-11-05 23:35:14 +01:00
Hermès Bélusca-Maïto 3d137b05d1
[SETUPLIB][USETUP] Move all the code that performs file copying into the SETUPLIB. 2018-11-05 23:18:47 +01:00
Hermès Bélusca-Maïto f894631472
[SETUPLIB][USETUP] Add support for setup error handling. 2018-11-05 12:03:19 +01:00
Thomas Faber 8bb1b39f66
[REACTOS] Don't include another module's PCH aka fix build. 2018-11-02 11:14:09 +01:00
Hermès Bélusca-Maïto 8cbaca5724
[REACTOS] Temporarily exclude the 1st-stage GUI setup from build, until I (or someone else) finds the correct way to fix the GCC builds. 2018-11-01 23:20:27 +01:00
Hermès Bélusca-Maïto 1b0c26e21c
[SETUPLIB][USETUP] Minor improvements.
- Use adequate access flag when opening symbolic links.
- Simplify the prototype of UpdateRegistry() since now both Setup INF
  handle and settings lists are inside the USETUP_DATA structure.
2018-11-01 18:55:45 +01:00
Hermès Bélusca-Maïto 13998a15c9
[USETUP] Improve SetupCommitFileQueueW() to make it compatible with its Win32 counterpart.
This means, call in the correct order the user callback with the correct
parameters (in particular the correct paths for file copy operations),
and check also for the callback returned value to know whether or not to
continue the file operations.
2018-11-01 18:55:44 +01:00
Hermès Bélusca-Maïto 8f1ab791fa
[SETUPLIB][REACTOS][USETUP] Further improve the interfacing with INF and File-Queue APIs.
This allows using some of the SetupApi.dll functions when SETUPLIB is
used in the (Win32) GUI 1st-stage installer "REACTOS", while using the
custom implemented NT-aware functions in "USETUP".
2018-11-01 18:55:43 +01:00
Hermès Bélusca-Maïto 44c101c9dc
[USETUP] Improvements for the File-queues code.
- Add support for delete and move/rename operations, which are needed
  for implementing ReactOS upgrading support.

- Use cabinet contexts.
- Use standard LIST_ENTRY structures for implementing the lists.

- Move the path-building hack code in SetupCommitFileQueueW() that had
  been introduced in r66604 (97bb83f) out of the file-queues code.

- Make the function prototypes compatible with win32's setupapi functions.
- Fix the format of the data passed to the custom notification handler.
- Adjust the file-copy callback to correctly use its arguments (setupapi-compatible).
2018-11-01 18:55:35 +01:00
Hermès Bélusca-Maïto 9169e881aa
[USETUP] Refactor the cabinet handling code to place all the global state variables into a CABINET_CONTEXT structure.
Place also all the private cabinet definitions into the .c, keeping
into the header file only the "public" structures and function prototypes.
2018-10-28 23:57:06 +01:00
Hermès Bélusca-Maïto 1a173dfdb2
[SETUPLIB][REACTOS][USETUP] Re-organize the setup state variables and some helpers.
- Move a great deal of global variables into the USETUP_DATA structure
  (the SetupInf, the SetupFileQueue, the generic lists...).

- Place the common setup initialization code into an InitializeSetup()
  routine, and the cleanup code into FinishSetup().

- Implement the setup-code part support for the TXTSETUP.SIF setup
  source path override variables "SetupSourceDevice" and "SetupSourcePath"
  (see CORE-9023); support for them in SETUPLDR will be added later.
2018-10-28 23:40:28 +01:00
Hermès Bélusca-Maïto 9016b5f3ef
[SETUPLIB] Silence noisy DPRINTs. 2018-10-28 23:40:26 +01:00
Hermès Bélusca-Maïto 4bf9f6fa4a
[SETUP:REACTOS] Populate the list of existing installations.
- In the 1st-stage GUI setup, display the list of existing discovered
  NTOS installations, with its name, installation path and vendor name,
  and an associated icon.
2018-10-28 19:00:01 +01:00
Hermès Bélusca-Maïto f7ee1e2ffd
[SETUP:REACTOS] Add a wizard page to select which existing OS installation to upgrade. 2018-10-28 18:59:56 +01:00
Hermès Bélusca-Maïto 82117d2192
[SETUP:REACTOS] Adapt the 1st-stage GUI setup to compile with the setuplib.
svn path=/branches/setup_improvements/; revision=75544

[SETUP:REACTOS] More interfacing of the 1st-stage GUI installer with the setuplib.

- Add a ConvertNtPathToWin32Path() helper function that allows converting
  NT paths like: \Device\CdRom0\i386\txtsetup.sif file into a Win32 path
  that the Win32 versions of the SetupApi functions (e.g. SetupOpenInfFileW)
  can accept.
  Note that RtlNtPathNameToDosPathName() cannot be used here because this
  function only works for NT paths within the \DosDevices\ (or \??\) NTObj
  directory, and not in other directories.

- Use this helper function in the implementation of SetupOpenInfFileExW.
  Now the txtsetup.sif function can be loaded by setuplib *when being used*
  by the 1st-stage GUI installer!

- Remove deprecated code.

svn path=/branches/setup_improvements/; revision=75668
svn path=/branches/setup_improvements/; revision=75721
svn path=/branches/setup_improvements/; revision=75750
2018-10-28 18:59:47 +01:00
Hermès Bélusca-Maïto 9c64b57dc9
[SETUPLIB][USETUP] Move the remaining (directory-creation) functions from usetup's filesup to setuplib.
They will be used later in the library.
2018-10-28 18:17:34 +01:00
Hermès Bélusca-Maïto a972948051
[SETUPLIB][USETUP] Remove the deprecated GenericListHasSingleEntry() function and use instead GetNumberOfListEntries().
- Few FIXMEs get fixed in the process.
- Add some diagnostic ASSERTs.
2018-10-28 15:04:33 +01:00
Hermès Bélusca-Maïto a635aa8475
[SETUPLIB] Properly cleanup the temporary registry keys created for setting up the registry.
This includes also to remove the created symlinks.
Symlinks deletion is special, as one has to open first the symlink
itself (and not its target), then remove the "SymbolicLinkTarget" value
before really deleting the key. Of course everything must be done under
proper access rights.

Additional changes:
- Change prototype BOOLEAN CmpLinkKeyToHive(...) to NTSTATUS CreateSymLinkKey(...).
- Silence few DPRINTs.
- Document some FIXMEs that I need to inspect later on ReactOS.
- HKEY --> HANDLE.
2018-10-28 14:42:01 +01:00
Hermès Bélusca-Maïto 6c2d3dee04
[SETUPLIB][USETUP] Move the registry-update procedure into setuplib.
- It can therefore be also used by the 1st-stage GUI setup.
- Rename some function parameters to clarify what they should be.

Based on:
svn path=/branches/setup_improvements/; revision=75750
2018-10-28 14:42:00 +01:00
Hermès Bélusca-Maïto dae658088a
[USETUP] Introduce some -V functions for CONSOLE_ConOutPrintf, CONSOLE_SetStatusText and CONSOLE_SetStatusTextX.
Additions:
- Use explicit __cdecl calling convention for variadic functions.
- Fix also the whitespace in consup.h.

svn path=/branches/setup_improvements/; revision=75749
2018-10-28 14:41:57 +01:00
Hermès Bélusca-Maïto f80ec8b822
[SETUPLIB] Store the vendor name for each discovered NTOS installation.
Take also the opportunity to simplify a little bit the code.
2018-10-28 01:58:59 +02:00