From 17687e7d2c4e9ec1ec7e33477dcf04632b2720b4 Mon Sep 17 00:00:00 2001 From: "Edward A. Lee" Date: Thu, 21 Nov 2024 15:00:50 -0800 Subject: [PATCH 1/2] Define LF_FILE_SEPARATOR in CMake --- .../java/org/lflang/federated/extensions/CExtensionUtils.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java b/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java index 541ff67f74..12c93e0092 100644 --- a/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java +++ b/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java @@ -313,6 +313,8 @@ public static void generateCMakeInclude( "add_compile_definitions(LF_PACKAGE_DIRECTORY=\"" + fileConfig.srcPkgPath + "\")"); cmakeIncludeCode.pr( "add_compile_definitions(LF_SOURCE_GEN_DIRECTORY=\"" + fileConfig.getSrcGenPath() + "\")"); + cmakeIncludeCode.pr( + "add_compile_definitions(LF_FILE_SEPARATOR=\"" + File.separator + "\")"); try (var srcWriter = Files.newBufferedWriter(cmakeIncludePath)) { srcWriter.write(cmakeIncludeCode.getCode()); } From 554b34e58e7959746fa7cfc6897bb6aefc7916ed Mon Sep 17 00:00:00 2001 From: "Edward A. Lee" Date: Thu, 21 Nov 2024 17:40:39 -0800 Subject: [PATCH 2/2] Silly formatting --- .../java/org/lflang/federated/extensions/CExtensionUtils.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java b/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java index 12c93e0092..ad982431a2 100644 --- a/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java +++ b/core/src/main/java/org/lflang/federated/extensions/CExtensionUtils.java @@ -313,8 +313,7 @@ public static void generateCMakeInclude( "add_compile_definitions(LF_PACKAGE_DIRECTORY=\"" + fileConfig.srcPkgPath + "\")"); cmakeIncludeCode.pr( "add_compile_definitions(LF_SOURCE_GEN_DIRECTORY=\"" + fileConfig.getSrcGenPath() + "\")"); - cmakeIncludeCode.pr( - "add_compile_definitions(LF_FILE_SEPARATOR=\"" + File.separator + "\")"); + cmakeIncludeCode.pr("add_compile_definitions(LF_FILE_SEPARATOR=\"" + File.separator + "\")"); try (var srcWriter = Files.newBufferedWriter(cmakeIncludePath)) { srcWriter.write(cmakeIncludeCode.getCode()); }