Selaa lähdekoodia

Fix Makefile to work with osx hostname -s

uname -n uses/catches dhcp addresses, which is dumb.
master
Mitch Tishmack 9 vuotta sitten
vanhempi
commit
cf12fd8334
1 muutettua tiedostoa jossa 6 lisäystä ja 1 poistoa
  1. +6
    -1
      Makefile

+ 6
- 1
Makefile Näytä tiedosto

@@ -8,7 +8,10 @@ LASTGEN:=$(PWD)/generation/$(LAST)
TANGLERS:=$(shell ls -d *.org)
GEN:=$(LAST)
OPTS:=
HOST:=$(shell uname -n)
# OSX uses hostname -s for the "stable" hostname
# uname -n can return dhcp addresses, which aren't
# stable.
HOST=$(shell echo "$$(hostname -s || uname -n)")
USEROPTS:=$(OPTS):$(HOST)
NAME:=default

@@ -31,11 +34,13 @@ next: diff

.PHONY: tangle-next
tangle-next:
@echo Tangling for hostname $(HOST)
$(MAKE) tangle
$(MAKE) generation
$(MAKE) next
$(MAKE) copy GEN=$(NEXT)
@echo $(NEXT) > .last
@echo Tangled for hostname $(HOST)

copy:
cd $(PWD)/generation/$(GEN) && find . -type f -exec rm -f $(DEST)/{} \;


Ladataan…
Peruuta
Tallenna