]> git.ipfire.org Git - ipfire-2.x.git/blobdiff - lfs/flash-images
Merge branch 'next' of ssh://git.ipfire.org/pub/git/ipfire-2.x into asterisk-update
[ipfire-2.x.git] / lfs / flash-images
index 79701aad96713a2130e02fae9dd916840c35c2bf..d2050b4ab3ead388f4b86e55f0845aaebabd57e5 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2012  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2014  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -31,7 +31,7 @@ TARGET     = $(DIR_INFO)/$(THISAPP)
 
 DEVICE     = $(shell losetup -f)
 PART_BOOT  = /dev/mapper/$(patsubst /dev/%,%,$(DEVICE))p1
-PART_ROOT  = /dev/mapper/$(patsubst /dev/%,%,$(DEVICE))p2
+PART_ROOT  = /dev/mapper/$(patsubst /dev/%,%,$(DEVICE))p3
 
 ifeq "$(SCON)" "1"
        IMAGE_FILE = /install/images/$(SNAME)-$(VERSION).1gb-ext4-scon.$(MACHINE)-full-core$(CORE).img.gz
@@ -92,7 +92,7 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        losetup $(DEVICE) $(IMG)
 
        # Write Partition table
-       echo -e "$(S_OFFSET),$(S_BOOT),$(PART_TYPE),*\n$$(( $(S_BOOT) + $(S_OFFSET) )),$(S_ROOT),L\n" \
+       echo -e "$(S_OFFSET),$(S_BOOT),$(PART_TYPE),*\n,0,0\n$$(( $(S_BOOT) + $(S_OFFSET) )),$(S_ROOT),L\n" \
                | sfdisk -D -uS -H 64 -S 32 $(DEVICE)
 
        kpartx -v -a $(DEVICE)
@@ -127,8 +127,11 @@ ifeq "$(MACHINE_TYPE)" "arm"
 endif
 
        # Install IPFire
+ifneq "$(MACHINE_TYPE)" "arm"
        tar -x --lzma -C $(MNThdd)/ -f /install/cdrom/distro.img
-
+else
+       tar -x -C $(MNThdd)/ -f /install/cdrom/distro.img
+endif
        echo "LANGUAGE=en" >> $(MNThdd)/var/ipfire/main/settings
        echo "HOSTNAME=$(SNAME)" >> $(MNThdd)/var/ipfire/main/settings
        echo "THEME=ipfire" >> $(MNThdd)/var/ipfire/main/settings
@@ -167,7 +170,7 @@ endif
 ifeq "$(BOOTLOADER)" "grub"
 ifeq "$(SCON)" "1"
        # Enable serial console on GRUB
-       echo "GRUB_TERMINAL=\"serial console\"" >> $(MNThdd)/etc/default/grub
+       echo "GRUB_TERMINAL=\"serial\"" >> $(MNThdd)/etc/default/grub
        echo "GRUB_SERIAL_COMMAND=\"serial --unit=0 --speed=115200\"" >> $(MNThdd)/etc/default/grub
 
        sed -i -e "s|panic=10|& console=ttyS0,115200n8|g" $(MNThdd)/etc/default/grub