JetBrains / JetBrainsRuntime

Runtime environment based on OpenJDK for running IntelliJ Platform-based products on Windows, macOS, and Linux
GNU General Public License v2.0
1.26k stars 192 forks source link

JBR-6785 wsl: update build scripts for linux target #330

Closed avu closed 5 months ago

avu commented 5 months ago

Added explicit platform target

vprovodin commented 5 months ago

These changes break linux-musl builds. I would suggest to slightly modify the script as follows

@@ -25,6 +25,13 @@
 JCEF_PATH=${JCEF_PATH:=./jcef_linux_x64}

 function do_configure {
+  if is_musl; then
+    LINUX_TARGET=""
+  else
+    LINUX_TARGET="\
+      --build=x86_64-unknown-linux-gnu \
+      --openjdk-target=x86_64-unknown-linux-gnu"
+  fi
   sh configure \
     $WITH_DEBUG_LEVEL \
     --with-vendor-name="$VENDOR_NAME" \
@@ -35,8 +42,7 @@
     --with-version-opt=b"$build_number" \
     --with-boot-jdk="$BOOT_JDK" \
     --enable-cds=yes \
-    --build=x86_64-unknown-linux-gnu \
-    --openjdk-target=x86_64-unknown-linux-gnu \
+    $LINUX_TARGET \
     $STATIC_CONF_ARGS \
     $REPRODUCIBLE_BUILD_OPTS \
     $WITH_ZIPPED_NATIVE_DEBUG_SYMBOLS \