Makefile: Make the sysconfig target inside the chroot

This commit is contained in:
Albert Hopkins 2015-02-27 22:12:46 +00:00
parent 1a9d97d016
commit 27f7653ee7
1 changed files with 5 additions and 4 deletions

View File

@ -16,6 +16,7 @@ SOFTWARE = $(CHROOT)/tmp/software
KERNEL = $(CHROOT)/tmp/kernel KERNEL = $(CHROOT)/tmp/kernel
GRUB = $(CHROOT)/tmp/grub GRUB = $(CHROOT)/tmp/grub
PREPROOT = $(CHROOT)/tmp/preproot PREPROOT = $(CHROOT)/tmp/preproot
SYSCONFIG = $(CHROOT)/tmp/sysconfig
STAGE4_TARBALL = $(CURDIR)/images/$(APPLIANCE).tar.xz STAGE4_TARBALL = $(CURDIR)/images/$(APPLIANCE).tar.xz
VIRTIO = NO VIRTIO = NO
TIMEZONE = UTC TIMEZONE = UTC
@ -191,14 +192,14 @@ else
sed -i '/swap/d' $(CHROOT)/etc/fstab sed -i '/swap/d' $(CHROOT)/etc/fstab
endif endif
sysconfig: $(PREPROOT) $(SWAP_FILE) $(SYSCONFIG): $(PREPROOT) $(SWAP_FILE)
@echo $(VIRTIO) @echo $(VIRTIO)
ifeq ($(VIRTIO),YES) ifeq ($(VIRTIO),YES)
sed -i 's/sda/vda/' $(CHROOT)/etc/fstab sed -i 's/sda/vda/' $(CHROOT)/etc/fstab
endif endif
touch sysconfig touch $(SYSCONFIG)
systools: sysconfig $(COMPILE_OPTIONS) systools: $(SYSCONFIG) $(COMPILE_OPTIONS)
@scripts/echo Installing standard system tools @scripts/echo Installing standard system tools
-$(inroot) $(EMERGE) --unmerge sys-fs/udev -$(inroot) $(EMERGE) --unmerge sys-fs/udev
$(inroot) $(EMERGE) $(USEPKG) -n1 sys-apps/systemd $(inroot) $(EMERGE) $(USEPKG) -n1 sys-apps/systemd
@ -335,7 +336,7 @@ eclean: $(COMPILE_OPTIONS)
clean: clean:
rm -f sysconfig systools rm -f systools
rm -rf --one-file-system -- $(CHROOT) rm -rf --one-file-system -- $(CHROOT)
realclean: clean realclean: clean