From 17a1b8a507212e51e2c2df9090bf2fea40215ac1 Mon Sep 17 00:00:00 2001 From: Kevin Sapper Date: Fri, 3 Feb 2017 16:57:16 +0100 Subject: [PATCH] Problem: [c_v1] codec API is generated outside zproject Solution: Check the zproject switch and make sure the zproto codec is mapped to a public class before generating the API xml. --- src/zproto_codec_c_v1.gsl | 8 +++++--- src/zproto_example.xml | 6 +++++- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/zproto_codec_c_v1.gsl b/src/zproto_codec_c_v1.gsl index 9401e7d..6a6c2c8 100644 --- a/src/zproto_codec_c_v1.gsl +++ b/src/zproto_codec_c_v1.gsl @@ -309,8 +309,9 @@ $(CLASS.EXPORT_MACRO)void #endif -.directory.create ("../api") -.output "../api/$(class.name).api" +.if switches.zproject ?= 1 & switches.private ?<> 1 +. directory.create ("../api") +. output "../api/$(class.name).api"