summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2016-05-02 13:18:24 -0400
committermidipix <writeonce@midipix.org>2016-05-02 13:18:24 -0400
commitcd7387feb48f667b727dcf5220d552f9ed406c01 (patch)
tree2d2d289a7bca04776961364312cf1c88c7cad185 /src
parentb66ee6bf6df3943015b1dcf33f448bae9b73ba57 (diff)
downloadslibtool-cd7387feb48f667b727dcf5220d552f9ed406c01.tar.bz2
slibtool-cd7387feb48f667b727dcf5220d552f9ed406c01.tar.xz
compile and link modes: .libs directory: properly handle parallel execution.
Diffstat (limited to 'src')
-rw-r--r--src/logic/slbt_exec_compile.c6
-rw-r--r--src/logic/slbt_exec_link.c6
2 files changed, 8 insertions, 4 deletions
diff --git a/src/logic/slbt_exec_compile.c b/src/logic/slbt_exec_compile.c
index 3d04304..c5c3e70 100644
--- a/src/logic/slbt_exec_compile.c
+++ b/src/logic/slbt_exec_compile.c
@@ -61,8 +61,10 @@ int slbt_exec_compile(
if ((fdlibs = open(ectx->ldirname,O_DIRECTORY)) >= 0)
close(fdlibs);
else if ((errno != ENOENT) || mkdir(ectx->ldirname,0777)) {
- slbt_free_exec_ctx(actx);
- return -1;
+ if (errno != EEXIST) {
+ slbt_free_exec_ctx(actx);
+ return -1;
+ }
}
}
diff --git a/src/logic/slbt_exec_link.c b/src/logic/slbt_exec_link.c
index 0230051..847bc95 100644
--- a/src/logic/slbt_exec_link.c
+++ b/src/logic/slbt_exec_link.c
@@ -1066,8 +1066,10 @@ int slbt_exec_link(
if ((fdlibs = open(ectx->ldirname,O_DIRECTORY)) >= 0)
close(fdlibs);
else if ((errno != ENOENT) || mkdir(ectx->ldirname,0777)) {
- slbt_free_exec_ctx(actx);
- return -1;
+ if (errno != EEXIST) {
+ slbt_free_exec_ctx(actx);
+ return -1;
+ }
}
}