ref: a5495bfdfcd30732c70b450df77d4df03f6b4a0d
parent: d58f623506477f6595143a3ee0bae1fe6735d694
author: Ori Bernstein <[email protected]>
date: Tue Aug 19 06:23:05 EDT 2014
Don't spuriously add include paths. Fix a dumb typo. Also, respect the include path order.
--- a/myrbuild/myrbuild.c
+++ b/myrbuild/myrbuild.c
@@ -195,10 +195,6 @@
char buf[1024];
size_t i;
- lappend(&incpaths, &nincpaths, strdup(Instroot "/lib/myr"));
- f = fopen(buf, "r");
- if (f)
- return f;
for (i = 0; i < nincpaths; i++) {
snprintf(buf, sizeof buf, "%s/%s", incpaths[i], lib);
f = fopen(buf, "r");
@@ -205,6 +201,10 @@
if (f)
return f;
}
+ snprintf(buf, sizeof buf, "%s/%s", Instroot "/lib/myr", lib);
+ f = fopen(buf, "r");
+ if (f)
+ return f;
err(1, "could not open library file %s\n", lib);
}