summaryrefslogtreecommitdiff
path: root/regress/libexec
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2013-10-18 09:59:56 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2013-10-18 09:59:56 +0000
commit5892b9ec72f81aea7708cd19201ff30d04b5b411 (patch)
treea6beee7cc4a660901d546c2c568321c9595ae064 /regress/libexec
parentf17afe12c24f04c1345de158e856fc2c487d9fb6 (diff)
Fix building regress outside of /usr/src where the objdir
behaviour is different. ok deraadt@ miod@
Diffstat (limited to 'regress/libexec')
-rw-r--r--regress/libexec/ld.so/dlopen/libac/Makefile11
1 files changed, 10 insertions, 1 deletions
diff --git a/regress/libexec/ld.so/dlopen/libac/Makefile b/regress/libexec/ld.so/dlopen/libac/Makefile
index 8aeef87649b..8102f02afc4 100644
--- a/regress/libexec/ld.so/dlopen/libac/Makefile
+++ b/regress/libexec/ld.so/dlopen/libac/Makefile
@@ -1,7 +1,16 @@
+.include <bsd.obj.mk>
+
+AA_DIR=${.CURDIR}/../libaa
+AA_OBJDIR!= if [ -d $(AA_DIR)/${__objdir} ]; then \
+ echo "$(AA_DIR)/${__objdir}"; \
+ else \
+ echo "$(AA_DIR)"; \
+ fi
+
LIB=ac
SRCS= ac.C
#CFLAGS=-I${.CURDIR}/../libaa
-LDADD=-L../libaa
+LDADD=-L$(AA_OBJDIR)
LDADD+=-laa
regress: all
.include <bsd.lib.mk>