1 # C client interface generation rules. 2 # 3 # Copyright (C) 2020 Paul Boddie <paul@boddie.org.uk> 4 # 5 # This program is free software; you can redistribute it and/or 6 # modify it under the terms of the GNU General Public License as 7 # published by the Free Software Foundation; either version 2 of 8 # the License, or (at your option) any later version. 9 # 10 # This program is distributed in the hope that it will be useful, 11 # but WITHOUT ANY WARRANTY; without even the implied warranty of 12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 # GNU General Public License for more details. 14 # 15 # You should have received a copy of the GNU General Public License 16 # along with this program; if not, write to the Free Software 17 # Foundation, Inc., 51 Franklin Street, Fifth Floor, 18 # Boston, MA 02110-1301, USA 19 20 define client_interface_c_template = 21 $(1)_CLIENT_IDL = $(call interfaces_to_idl,$(1)) 22 $(1)_CLIENT = $(call interfaces_to_client_c_h,$(1)) 23 24 # Reference interfaces if exported. 25 26 ifdef IDL_EXPORT_DIR 27 $(1)_CLIENT_INC = $(call export_includes,$(call interfaces_to_interface_h,$(1))) 28 endif 29 30 $$($(1)_CLIENT): $$($(1)_CLIENT_IDL) $$($(1)_CLIENT_INC) 31 $(IDL_PROG) -d $(IDL_BUILD_DIR) --client --headers --routines --language=c $$($(1)_CLIENT_IDL) 32 endef