From 3e7d5bf7bb66b14b327b6997b1793a6ceb3f8fc2 Mon Sep 17 00:00:00 2001
From: midipix <writeonce@midipix.org>
Date: Thu, 28 Apr 2016 17:17:50 -0400
Subject: execution context: added -rpath placeholders.

---
 include/slibtool/slibtool.h | 1 +
 src/logic/slbt_exec_ctx.c   | 8 ++++++++
 2 files changed, 9 insertions(+)

diff --git a/include/slibtool/slibtool.h b/include/slibtool/slibtool.h
index aacaa2b..30ad927 100644
--- a/include/slibtool/slibtool.h
+++ b/include/slibtool/slibtool.h
@@ -119,6 +119,7 @@ struct slbt_exec_ctx {
 	char ** symdefs;
 	char ** symfile;
 	char ** lout[2];
+	char ** rpath[2];
 	char ** sentinel;
 	FILE *	fwrapper;
 	FILE *	fdeps;
diff --git a/src/logic/slbt_exec_ctx.c b/src/logic/slbt_exec_ctx.c
index 17c6cd8..e874ec6 100644
--- a/src/logic/slbt_exec_ctx.c
+++ b/src/logic/slbt_exec_ctx.c
@@ -447,6 +447,10 @@ void slbt_reset_placeholders(struct slbt_exec_ctx * ectx)
 
 	*ectx->lout[0] = "-USLIBTOOL_PLACEHOLDER_OUTPUT_SWITCH";
 	*ectx->lout[1] = "-USLIBTOOL_PLACEHOLDER_OUTPUT_FILE";
+
+	*ectx->rpath[0] = "-USLIBTOOL_PLACEHOLDER_RPATH_SWITCH";
+	*ectx->rpath[1] = "-USLIBTOOL_PLACEHOLDER_RPATH_DIR";
+
 	*ectx->sentinel= 0;
 }
 
@@ -464,5 +468,9 @@ void slbt_disable_placeholders(struct slbt_exec_ctx * ectx)
 
 	*ectx->lout[0] = 0;
 	*ectx->lout[1] = 0;
+
+	*ectx->rpath[0] = 0;
+	*ectx->rpath[1] = 0;
+
 	*ectx->sentinel= 0;
 }
-- 
cgit v1.2.3