shithub: mc

Download patch

ref: bc6a44d5cc6fb0eab56e766bde325fa2a752c3a6
parent: 837deb5ccade25f83390d9b2af6a2369804514c8
author: Ori Bernstein <ori@eigenstate.org>
date: Tue Jan 6 10:50:48 EST 2015

myrbuild is a bootstrap tool.

    use mbld where available.

--- a/libstd/Makefile
+++ b/libstd/Makefile
@@ -99,10 +99,14 @@
 	cp $< $@
 
 lib$(STDLIB).a: $(STDSRC) $(ASMSRC) lib$(SYSLIB).a ../6/6m
-	../myrbuild/myrbuild -I. -C../6/6m -M../muse/muse -l $(STDLIB) $(STDSRC) $(STDASMSRC)
+	export MYR_MC=../6/6m && \
+	export MYR_MUSE=../muse/muse && \
+	./build.sh -l $(STDLIB) $(STDSRC) $(STDASMSRC)
 
 lib$(SYSLIB).a: $(SYSSRC) $(SYSASMSRC) ../6/6m
-	../myrbuild/myrbuild -C../6/6m -M../muse/muse -l $(SYSLIB) $(SYSSRC) $(SYSASMSRC)
+	export MYR_MC=../6/6m && \
+	export MYR_MUSE=../muse/muse && \
+	./build.sh -l $(SYSLIB) $(SYSSRC) $(SYSASMSRC)
 
 OBJ=$(STDSRC:.myr=.o) $(SYSSRC:.myr=.o) $(STDASMSRC:.s=.o) $(SYSASMSRC:.s=.o)
 USE=$(STDSRC:.myr=.use) $(SYSSRC:.myr=.use) $(STDLIB)
--- /dev/null
+++ b/libstd/build.sh
@@ -1,0 +1,8 @@
+#!/bin/bash
+
+if [ -z "`which xmbld`" ]; then
+    ../myrbuild/myrbuild -C$MYR_MC -M$MYR_MUSE $@
+else
+    mbld $@
+fi
+