From 7670c84f7732db29f5a9d9c145c2327f4b575f91 Mon Sep 17 00:00:00 2001 From: Paul Smith Date: Mon, 29 Oct 2012 07:05:21 +0000 Subject: Implement new "load" directive. Provides support for dynamically loadable objects in GNU make, as a "technology preview". --- tests/scripts/functions/guile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'tests/scripts/functions/guile') diff --git a/tests/scripts/functions/guile b/tests/scripts/functions/guile index 82c02bc..93a18ab 100644 --- a/tests/scripts/functions/guile +++ b/tests/scripts/functions/guile @@ -5,6 +5,20 @@ $description = 'Test the $(guile ...) function.'; $details = 'This only works on systems that support it.'; # If this instance of make doesn't support GNU Guile, skip it +# This detects if guile is loaded using the "load" directive +# $makefile = get_tmpfile(); +# open(MAKEFILE, "> $makefile") || die "Failed to open $makefile: $!\n"; +# print MAKEFILE q! +# -load guile +# all: ; @echo $(filter guile,$(.LOADED)) +# !; +# close(MAKEFILE) || die "Failed to write $makefile: $!\n"; +# $cmd = subst_make_string("#MAKEPATH# -f $makefile"); +# $log = get_logfile(0); +# $code = run_command_with_output($log, $cmd); +# read_file_into_string ($log) eq "guile\n" and $FEATURES{guile} = 1; + +# If we don't have Guile support, never mind. exists $FEATURES{guile} or return -1; # Verify simple data type conversions -- cgit v1.2.3