]> rtime.felk.cvut.cz Git - omk.git/commitdiff
Fix error with multiple IDL files
authorMichal Sojka <sojkam1@fel.cvut.cz>
Wed, 13 Nov 2013 05:11:37 +0000 (06:11 +0100)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Wed, 13 Nov 2013 05:11:37 +0000 (06:11 +0100)
... whitespace is sometimes important in Makefiles.

snippets/linux.omk
tests/idl

index 51d5dbfe8693e1a57972a70cb494d224d7e582e6..94400e18c7d6ec18c449875272577f0612e5fd36 100644 (file)
@@ -196,6 +196,7 @@ endef
 
 # Syntax: $(call COMPILE_idl_template,</path/to/src.idl>,<basename>)
 define COMPILE_idl_template
+
 ifeq ($$($(2)_IDL_TARGET),)
 $(2)_IDL_TARGET=1
 GEN_HEADERS+=$(filter %.h,$(notdir $(1:%.idl=%.h))) # Do we need this global variable?
index 17e082c95bedf3598dda3a953543249cd0234425..313c06384d52252a00c159090e6cdb28de5fb915 100755 (executable)
--- a/tests/idl
+++ b/tests/idl
@@ -26,6 +26,7 @@ lib_LIBRARIES = idlserver
 idlserver_SERVER_IDL = test.idl
 EOF
 
+create_idlcomp() {
 cat > idlcomp <<EOF
 #!/bin/sh
 out=\$(basename \${1%.idl})
@@ -37,6 +38,8 @@ echo "extern volatile int idl_skels;
       extern volatile int idl_stubs;" > \${out}.h
 EOF
 chmod +x idlcomp
+}
+create_idlcomp
 
 cat > testclient.c <<EOF
 #include "test.h"
@@ -59,3 +62,20 @@ EOF
 
 needs_valid_CC
 WVPASS make V=1 IDL_COMPILER=$PWD/idlcomp
+
+WVSTART "Two idl files in a program"
+create_idlcomp
+cat > test1.idl <<< "# IDL input for dummy IDL compiler"
+cat > test2.idl <<< "# IDL input for dummy IDL compiler"
+cat > testclient.c <<< "int main() {return 0;}"
+
+cat > Makefile.omk <<EOF
+bin_PROGRAMS = testclient
+INCLUDES=-I.
+
+testclient_SOURCES = testclient.c
+testclient_CLIENT_IDL = test1.idl test2.idl
+EOF
+cat > config.omk <<< IDL_COMPILER=$PWD/idlcomp
+
+WVPASS make