1 # C compound server 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 comp_interface_c_template = 21 $(1)_SERVER_IDL = $(call interfaces_to_idl,$(3)) 22 $(1)_SERVER = $(call interfaces_to_server_c_h,$(1)) 23 $(1)_SERVER_INC = $(call export_includes, $(call interfaces_to_interfaces_h,$(1))) 24 $(1)_SERVER_OPT = --comp=$(1) --comp-name=$(2) 25 26 $$($(1)_SERVER): $$($(1)_SERVER_IDL) $$($(1)_SERVER_INC) 27 $(IDL_PROG) -d $(IDL_BUILD_DIR) $$($(1)_SERVER_OPT) --headers --routines --language=c $$($(1)_SERVER_IDL) 28 endef