ramips: Add a tool to create JCG factory images
[openwrt/openwrt.git] / tools / firmware-utils / src / ptgen.c
index 68bad6fd974f261a6073047c3b5e8c95f0b4efdb..2b7ec25e4898abbc1508d8c2e20cfafae4a528c6 100644 (file)
@@ -26,6 +26,7 @@
 #include <unistd.h>
 #include <stdlib.h>
 #include <stdio.h>
+#include <stdint.h>
 #include <ctype.h>
 #include <fcntl.h>
 #include <stdint.h>
 #endif
 
 /* Partition table entry */
-struct pte { 
-       unsigned char active;
-       unsigned char chs_start[3];
-       unsigned char type;
-       unsigned char chs_end[3];
-       unsigned int start;
-       unsigned int length;
+struct pte {
+       uint8_t active;
+       uint8_t chs_start[3];
+       uint8_t type;
+       uint8_t chs_end[3];
+       uint32_t start;
+       uint32_t length;
 };
 
 struct partinfo {