--- a/configure.ac
+++ b/configure.ac
@@ -9139,7 +9139,7 @@ if test -n "$ENABLE_JAVA" -a -z "$JAVAIN
         test -d "$JAVA_HOME/include/native_thread" && JAVAINC="$JAVAINC -I$JAVA_HOME/include/native_thread"
         ;;
 
-    linux-gnu*)
+    linux-gnu*|linux-musl*)
         JAVAINC="-I$JAVA_HOME/include"
         JAVAINC="$JAVAINC -I$JAVA_HOME/include/linux"
         test -d "$JAVA_HOME/include/native_thread" && JAVAINC="$JAVAINC -I$JAVA_HOME/include/native_thread"
@@ -15386,7 +15386,7 @@ else
 
     case "$host_os" in
 
-    dragonfly*|freebsd*|linux-gnu*|*netbsd*|openbsd*)
+    dragonfly*|freebsd*|linux-gnu*|linux-musl*|*netbsd*|openbsd*)
         if test "$ENABLE_JAVA" != ""; then
             pathmunge "$JAVA_HOME/bin" "after"
         fi
--- a/configure
+++ b/configure
@@ -23269,7 +23269,7 @@ if test -n "$ENABLE_JAVA" -a -z "$JAVAIN
         test -d "$JAVA_HOME/include/native_thread" && JAVAINC="$JAVAINC -I$JAVA_HOME/include/native_thread"
         ;;
 
-    linux-gnu*)
+    linux-gnu*|linux-musl*)
         JAVAINC="-I$JAVA_HOME/include"
         JAVAINC="$JAVAINC -I$JAVA_HOME/include/linux"
         test -d "$JAVA_HOME/include/native_thread" && JAVAINC="$JAVAINC -I$JAVA_HOME/include/native_thread"
@@ -48847,7 +48847,7 @@ else
 
     case "$host_os" in
 
-    dragonfly*|freebsd*|linux-gnu*|*netbsd*|openbsd*)
+    dragonfly*|freebsd*|linux-gnu*|linux-musl*|*netbsd*|openbsd*)
         if test "$ENABLE_JAVA" != ""; then
             pathmunge "$JAVA_HOME/bin" "after"
         fi
