Skip to content

Commit 2c27e6f

Browse files
Do not include python codegen into cmake codegen (#10697)
1 parent 9335b61 commit 2c27e6f

File tree

1 file changed

+33
-23
lines changed

1 file changed

+33
-23
lines changed

ydb/core/base/generated/ya.make

Lines changed: 33 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -4,34 +4,44 @@ PEERDIR(
44
ydb/core/protos
55
)
66

7-
RUN_PROGRAM(
8-
ydb/core/base/generated/codegen
9-
runtime_feature_flags.h.in
7+
IF (EXPORT_CMAKE)
8+
# No Python codegen in cmake, pregenerate from ya to compile
9+
SRCS(
1010
runtime_feature_flags.h
11-
IN runtime_feature_flags.h.in
12-
OUT runtime_feature_flags.h
13-
OUTPUT_INCLUDES
14-
util/system/types.h
15-
atomic
16-
tuple
17-
)
18-
19-
RUN_PROGRAM(
20-
ydb/core/base/generated/codegen
21-
runtime_feature_flags.cpp.in
2211
runtime_feature_flags.cpp
23-
IN runtime_feature_flags.cpp.in
24-
OUT runtime_feature_flags.cpp
25-
OUTPUT_INCLUDES
26-
ydb/core/base/generated/runtime_feature_flags.h
27-
ydb/core/protos/feature_flags.pb.h
28-
)
12+
)
13+
ELSE()
14+
RUN_PROGRAM(
15+
ydb/core/base/generated/codegen
16+
runtime_feature_flags.h.in
17+
runtime_feature_flags.h
18+
IN runtime_feature_flags.h.in
19+
OUT runtime_feature_flags.h
20+
OUTPUT_INCLUDES
21+
util/system/types.h
22+
atomic
23+
tuple
24+
)
25+
26+
RUN_PROGRAM(
27+
ydb/core/base/generated/codegen
28+
runtime_feature_flags.cpp.in
29+
runtime_feature_flags.cpp
30+
IN runtime_feature_flags.cpp.in
31+
OUT runtime_feature_flags.cpp
32+
OUTPUT_INCLUDES
33+
ydb/core/base/generated/runtime_feature_flags.h
34+
ydb/core/protos/feature_flags.pb.h
35+
)
36+
ENDIF()
2937

3038
END()
3139

32-
RECURSE(
33-
codegen
34-
)
40+
IF (NOT EXPORT_CMAKE)
41+
RECURSE(
42+
codegen
43+
)
44+
ENDIF()
3545

3646
RECURSE_FOR_TESTS(
3747
ut

0 commit comments

Comments
 (0)