-/* Version number used for a different WIM format, which as of Windows 8 can be
- * created by passing 0x20000000 in dwFlagsAndAttributes to WIMGAPI's
- * WIMCreateFile() and specifying either NONE, XPRESS, or LZMS compression.
- * This format is currently undocumented by Microsoft and is seemingly
- * incompatible with their own ImageX and Dism programs; however, it seems to be
- * used for Windows 8 updates. The format appears to feature a new flag (0x10)
- * in resource entries, which I've named WIM_RESHDR_FLAG_CONCAT. */
-#define WIM_VERSION_STREAM_CONCAT 0xe00
-
-/* WIM magic characters, translated to a single 64-bit little endian number. */
-#define WIM_MAGIC \
- cpu_to_le64(((u64)'M' << 0) | \
- ((u64)'S' << 8) | \
- ((u64)'W' << 16) | \
- ((u64)'I' << 24) | \
- ((u64)'M' << 32) | \
- ((u64)'\0' << 40) | \
- ((u64)'\0' << 48) | \
- ((u64)'\0' << 54))
-
-/* wimlib pipable WIM magic characters, translated to a single 64-bit little
- * endian number. */
-#define PWM_MAGIC \
- cpu_to_le64(((u64)'W' << 0) | \
- ((u64)'L' << 8) | \
- ((u64)'P' << 16) | \
- ((u64)'W' << 24) | \
- ((u64)'M' << 32) | \
- ((u64)'\0' << 40) | \
- ((u64)'\0' << 48) | \
- ((u64)'\0' << 54))
-
-/* On-disk format of the WIM header. */
+/* Version number used for WIMs that allow multiple streams packed into one
+ * resource ("solid blocks", marked by WIM_RESHDR_FLAG_PACKED_STREAMS) and also
+ * a new compression format (LZMS). This version is new as of Windows 8
+ * WIMGAPI. Although it is used by Windows 8 web downloader, it is not yet
+ * properly documented by Microsoft. */
+#define WIM_VERSION_PACKED_STREAMS 0xe00
+
+/* Note: there is another WIM version from Vista pre-releases, but it is not
+ * supported by wimlib. */
+
+/* WIM magic characters, translated to a single 64-bit number. */
+#define WIM_MAGIC \
+ (((u64)'M' << 0) | \
+ ((u64)'S' << 8) | \
+ ((u64)'W' << 16) | \
+ ((u64)'I' << 24) | \
+ ((u64)'M' << 32) | \
+ ((u64)'\0' << 40) | \
+ ((u64)'\0' << 48) | \
+ ((u64)'\0' << 54))
+
+/* wimlib pipable WIM magic characters, translated to a single 64-bit number.
+ * */
+#define PWM_MAGIC \
+ (((u64)'W' << 0) | \
+ ((u64)'L' << 8) | \
+ ((u64)'P' << 16) | \
+ ((u64)'W' << 24) | \
+ ((u64)'M' << 32) | \
+ ((u64)'\0' << 40) | \
+ ((u64)'\0' << 48) | \
+ ((u64)'\0' << 54))
+
+/* On-disk format of the WIM header. */