summaryrefslogtreecommitdiff
path: root/testsuite/tests/package/T20010/Makefile
blob: 9343836a5ed0f6a6c643e2a332cc291bc1d0fa64 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
TOP=../../../..
include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk

T20010:
	'$(TEST_HC)' $(TEST_HC_OPTS) -c T20010.hs
	'$(TEST_HC)' $(TEST_HC_OPTS) -c T20010_c.cpp
	'$(TEST_HC)' $(TEST_HC_OPTS) -package system-cxx-std-lib T20010_c.o T20010.o -o T20010
	./T20010

T20010-ghci:
	'$(TEST_HC)' $(TEST_HC_OPTS) -c T20010.hs
	# We must build with PIC lest we end up with R_X86_64_32 relocations in
	# .rodata which precludes linking into a shared object and therefore loading
	# in GHCi
	'$(TEST_HC)' $(TEST_HC_OPTS) -c -fPIC T20010_c.cpp
	'$(TEST_HC)' $(TEST_HC_OPTS_INTERACTIVE) -package system-cxx-std-lib T20010_c.o <T20010-ghci.script