@@ -22,11 +22,11 @@ _PY_FBS_DEPS=contrib/python/flatbuffers
22
22
### processed when --add-flatbuf-result flag is specified on the command line
23
23
### for 'ya make ...' (tar archive is extracted to output directory).
24
24
macro FBS_TO_PYSRC(OUT_NAME, IN_FBS_FILES...) {
25
- .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --python --no-warnings --python-typing --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:IN_FBS_FILES} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --exts .py --input $BINDIR --output ${output; noauto;tared:OUT_NAME.py3.fbs.pysrc} ${kv; hide:"p FP"} ${kv; hide:"pc light-green"} ${kv; hide:"tared_kind nodir"} ${hide:FBS_FAKEID}
25
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --python --no-warnings --python-typing --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:IN_FBS_FILES} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --exts .py --input $BINDIR --output ${noauto;output; tared:OUT_NAME.py3.fbs.pysrc} ${hide;kv :"p FP"} ${hide;kv :"pc light-green"} ${hide;kv :"tared_kind nodir"} ${hide:FBS_FAKEID}
26
26
}
27
27
28
28
macro FBS_TO_PY2SRC(OUT_NAME, IN_FBS_FILES...) {
29
- .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:"contrib/deprecated/flatc"} --python --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:IN_FBS_FILES} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --exts .py --input $BINDIR --output ${output; noauto;tared:OUT_NAME.py2.fbs.pysrc} ${kv; hide:"p FP"} ${kv; hide:"pc light-green"} ${kv; hide:"tared_kind nodir"} ${hide:FBS_FAKEID}
29
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:"contrib/deprecated/flatc"} --python --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:IN_FBS_FILES} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --exts .py --input $BINDIR --output ${noauto;output; tared:OUT_NAME.py2.fbs.pysrc} ${hide;kv :"p FP"} ${hide;kv :"pc light-green"} ${hide;kv :"tared_kind nodir"} ${hide:FBS_FAKEID}
30
30
}
31
31
32
32
# tag:fbs tag:go-specific
@@ -38,14 +38,14 @@ _GO_FLATC_IMPORTS=\
38
38
39
39
# tag:fbs tag:cpp-specific
40
40
macro _CPP_FLATC_CMD(SRC, SRCFLAGS...) {
41
- .CMD=${cwd:ARCADIA_BUILD_ROOT} $YMAKE_PYTHON3 ${input:"build/scripts/cpp_flatc_wrapper.py"} ${tool:FLATC} --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${output;main;norel:SRC.h} ${output; hide;norel:SRC.cpp} ${input:SRC} ${output; hide;noext;norel:SRC.iter.fbs.h} ${output ;noauto;hide ;noext;norel:SRC.bfbs} ${kv; hide:"p FL"} ${kv; hide:"pc light-green"} ${hide:FBS_FAKEID}
42
- .SEM=target_fbs_source PRIVATE ${input:SRC} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} ${output; hide;norel:SRC.h} ${output; hide;norel:SRC.cpp} ${output; hide;noext;norel:SRC.iter.fbs.h} ${output ;noauto;hide ;noext;norel:SRC.bfbs} ${hide;tool:FLATC} && target_macroses-ITEM && target_macroses-macro target_fbs_source && target_macroses-args PRIVATE ${input:SRC} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} ${output; hide;norel:SRC.h} ${output; hide;norel:SRC.cpp} ${output; hide;noext;norel:SRC.iter.fbs.h} ${output ;noauto;hide ;noext;norel:SRC.bfbs} ${hide;tool:FLATC} && set_global_flags FBS_CPP_FLAGS --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs && platform_vars-FBS_CPP_FLAGS "--no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs" ${input; hide:"build/scripts/cpp_flatc_wrapper.py"}
41
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} $YMAKE_PYTHON3 ${input:"build/scripts/cpp_flatc_wrapper.py"} ${tool:FLATC} --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${output;main;norel:SRC.h} ${hide;output; norel:SRC.cpp} ${input:SRC} ${hide;output; noext;norel:SRC.iter.fbs.h} ${hide ;noauto;output ;noext;norel:SRC.bfbs} ${hide;kv :"p FL"} ${hide;kv :"pc light-green"} ${hide:FBS_FAKEID}
42
+ .SEM=target_fbs_source PRIVATE ${input:SRC} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} ${hide;output; norel:SRC.h} ${hide;output; norel:SRC.cpp} ${hide;output; noext;norel:SRC.iter.fbs.h} ${hide ;noauto;output ;noext;norel:SRC.bfbs} ${hide;tool:FLATC} && target_macroses-ITEM && target_macroses-macro target_fbs_source && target_macroses-args PRIVATE ${input:SRC} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} ${hide;output; norel:SRC.h} ${hide;output; norel:SRC.cpp} ${hide;output; noext;norel:SRC.iter.fbs.h} ${hide ;noauto;output ;noext;norel:SRC.bfbs} ${hide;tool:FLATC} && set_global_flags FBS_CPP_FLAGS --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs && platform_vars-FBS_CPP_FLAGS "--no-warnings --cpp --keep-prefix --gen-mutable --schema -b --yandex-maps-iter --gen-object-api --filename-suffix .fbs" ${hide;input :"build/scripts/cpp_flatc_wrapper.py"}
43
43
.PEERDIR=contrib/libs/flatbuffers
44
44
}
45
45
46
46
# tag:fbs tag:cpp-specific
47
47
macro _CPP_FLATC64_CMD(SRC, SRCFLAGS...) {
48
- .CMD=${cwd:ARCADIA_BUILD_ROOT} $YMAKE_PYTHON3 ${input:"build/scripts/cpp_flatc_wrapper.py"} ${tool:FLATC64} --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --filename-suffix .fbs64 ${FLATC_FLAGS_VALUE} -I ${ARCADIA_ROOT} -I ${ARCADIA_BUILD_ROOT} -o ${output;main;norel:SRC.h} ${output; hide;norel:SRC.cpp} ${input:SRC} ${output ;noauto;hide ;noext;norel:SRC.bfbs64} ${kv; hide:"p FL64"} ${kv; hide:"pc light-green"} ${hide:FBS_FAKEID}
48
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} $YMAKE_PYTHON3 ${input:"build/scripts/cpp_flatc_wrapper.py"} ${tool:FLATC64} --no-warnings --cpp --keep-prefix --gen-mutable --schema -b --filename-suffix .fbs64 ${FLATC_FLAGS_VALUE} -I ${ARCADIA_ROOT} -I ${ARCADIA_BUILD_ROOT} -o ${output;main;norel:SRC.h} ${hide;output; norel:SRC.cpp} ${input:SRC} ${hide ;noauto;output ;noext;norel:SRC.bfbs64} ${hide;kv :"p FL64"} ${hide;kv :"pc light-green"} ${hide:FBS_FAKEID}
49
49
.PEERDIR=contrib/libs/flatbuffers64
50
50
}
51
51
@@ -57,7 +57,7 @@ macro _CPP_FLATC64_CMD(SRC, SRCFLAGS...) {
57
57
### --add-protobuf-result flag is specified on the command line for 'ya make ...'
58
58
### (tar archive is extracted to output directory).
59
59
macro _GO_FLATC_CMD(SRC, PACKAGE_NAME) {
60
- .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --go --gen-mutable --go-namespace ${PACKAGE_NAME} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR}/_generated ${input:SRC} && $YMAKE_PYTHON3 ${input:"build/scripts/postprocess_go_fbs.py"} --arcadia-prefix ${GO_ARCADIA_PROJECT_PREFIX} --input-dir ${BINDIR} --map $_FBS_NAMESPACE_MAP_GLOBAL && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --flat --input ${BINDIR}/_generated --output ${output;noext;tared:SRC.fbs.gosrc} --exts .go ${kv; hide:"p FG"} ${kv; hide:"pc light-green"} ${kv; hide:"tared_kind nodir"} ${hide:FBS_FAKEID}
60
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --go --gen-mutable --go-namespace ${PACKAGE_NAME} ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR}/_generated ${input:SRC} && $YMAKE_PYTHON3 ${input:"build/scripts/postprocess_go_fbs.py"} --arcadia-prefix ${GO_ARCADIA_PROJECT_PREFIX} --input-dir ${BINDIR} --map $_FBS_NAMESPACE_MAP_GLOBAL && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --flat --input ${BINDIR}/_generated --output ${output;noext;tared:SRC.fbs.gosrc} --exts .go ${hide;kv :"p FG"} ${hide;kv :"pc light-green"} ${hide;kv :"tared_kind nodir"} ${hide:FBS_FAKEID}
61
61
.PEERDIR=${_GO_FLATC_IMPORTS}
62
62
}
63
63
@@ -69,7 +69,7 @@ macro _GO_FLATC_CMD(SRC, PACKAGE_NAME) {
69
69
### be added to results when --add-flatbuf-result flag is specified on the command
70
70
### line for 'ya make ...'
71
71
macro _JAVA_FLATC_CMD(SRC, SRCFLAGS...) {
72
- .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --java --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:SRC} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --input $BINDIR --output ${output;nopath;noext:SRC.fbs.jsrc} --exts .java ${kv; hide:"p FJ"} ${kv; hide:"pc light-green"} ${hide:FBS_FAKEID}
72
+ .CMD=${cwd:ARCADIA_BUILD_ROOT} ${tool:FLATC} --java --gen-mutable ${FLATC_FLAGS_VALUE} ${pre=-I :_FLATC__INCLUDE} -o ${BINDIR} ${input:SRC} && $YMAKE_PYTHON3 ${input:"build/scripts/tar_sources.py"} --input $BINDIR --output ${output;nopath;noext:SRC.fbs.jsrc} --exts .java ${hide;kv :"p FJ"} ${hide;kv :"pc light-green"} ${hide:FBS_FAKEID}
73
73
.PEERDIR=contrib/java/com/google/flatbuffers/flatbuffers-java/${JAVA_FLATBUFFERS_VERSION}
74
74
}
75
75
@@ -149,7 +149,7 @@ macro FBS_CMD(SRC, SRCFLAGS...) {
149
149
###
150
150
### Produce flatbuf schema out of protobuf description.
151
151
macro PROTO2FBS(File) {
152
- .CMD=${cwd:BINDIR} ${tool:FLATC} -I . -I ${ARCADIA_ROOT} --proto ${input:File} ${output; hide;norel;noext:File.fbs} ${kv; hide:"p FBS"} ${kv; hide:"pc yellow"} && $MOVE_FILE ${BINDIR}/${nopath;noext:File.fbs} ${output;norel;noext:File.fbs}
152
+ .CMD=${cwd:BINDIR} ${tool:FLATC} -I . -I ${ARCADIA_ROOT} --proto ${input:File} ${hide;output; norel;noext:File.fbs} ${hide;kv :"p FBS"} ${hide;kv :"pc yellow"} && $MOVE_FILE ${BINDIR}/${nopath;noext:File.fbs} ${output;norel;noext:File.fbs}
153
153
}
154
154
155
155
_CPP_FLATC_CMDLINE=$_CPP_FLATC_CMD($SRC $SRCFLAGS)
0 commit comments