ref: 25f2319f74103671395d0c151c550abe16928f62
parent: e0c639bd2eb7214fc1521c934b6033ee5b12b928
author: Ori Bernstein <[email protected]>
date: Thu Dec 25 19:27:59 EST 2014
More tweaks towards working tests.
--- a/libstd/mkfile
+++ b/libstd/mkfile
@@ -1,4 +1,4 @@
-.</$objtype/mkfile
+</$objtype/mkfile
SYSLIB=sys
SYSSRC= \
--- a/myrbuild/myrbuild.c
+++ b/myrbuild/myrbuild.c
@@ -29,7 +29,7 @@
char *as[] = Asmcmd;
char *ar[] = Arcmd;
char *ld[] = Ldcmd;
-char *runtime = Instroot "/lib/myr/_myrrt";
+char *runtime = Instroot "/lib/myr/_myrrt" Objsuffix;
/* the name of the output file */
char *libname;
char *binname;
@@ -461,8 +461,7 @@
}
if (runtime) {
- snprintf(buf, sizeof buf, "%s%s", runtime, Objsuffix);
- lappend(&args, &nargs, strdup(buf));
+ lappend(&args, &nargs, strdup(runtime));
}
/* ld -T ldscript -o outfile foo.o bar.o baz.o */
@@ -508,6 +507,7 @@
int main(int argc, char **argv)
{
struct utsname name;
+ char buf[512];
char **stack;
size_t nstack;
Optctx ctx;
--- a/test/runtest.rc
+++ b/test/runtest.rc
@@ -5,7 +5,8 @@
nfailed=0
fn build {
- rm -f $1 $1^.o $1^.s $1^.use
+ rm -f $1 $1^.6 $1^.s $1^.use
+ echo ../myrbuild/6.out -b $1 -C../6/6.out -M../muse/6.out -I../libstd -r../rt/_myrrt.6 $1^.myr
../myrbuild/6.out -b $1 -C../6/6.out -M../muse/6.out -I../libstd -r../rt/_myrrt.6 $1^.myr
}
@@ -20,7 +21,7 @@
fn expectstatus {
./$1 $3
- if(~ $status $2){
+ if(~ *$status $2){
pass $1
return
}