summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorNicolás Bértolo <nicolasbertolo@gmail.com>2020-05-22 17:54:41 -0300
committerDavid Malcolm <dmalcolm@redhat.com>2020-05-28 14:43:58 -0400
commitc83027f32d9cca84959c7d6a1e519a0129731501 (patch)
tree4dad20ef88f0f41236b4da3f2e2c90c5ce1da512 /configure
parentccf4e86dc01d8c89a8d56b228757a689d1fcc564 (diff)
jit: port libgccjit to Windows
2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> /ChangeLog: * configure.ac: Don't require --enable-host-shared when building for Mingw. * configure: Regenerate. 2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> gcc/ChangeLog: * Makefile.in: don't look for libiberty in the "pic" subdirectory when building for Mingw. Add dependency on xgcc with the proper extension. 2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> gcc/c/ChangeLog: * Make-lang.in: Remove extra slash. 2020-05-28 Nicolas Bértolo <nicolasbertolo@gmail.com> gcc/jit/ChangeLog: * Make-lang.in: Remove extra slash. Build libgccjit.dll and its import library in Windows. * config-lang.in: Update comment about --enable-host-shared. * jit-w32.h: New file. * jit-w32.c: New file. (print_last_error): New function that prints the error string corresponding to GetLastError(). (get_TOKEN_USER_current_user): Helper function used for getting the SID belonging to the current user. (create_directory_for_current_user): Helper function to create a directory with permissions such that only the current user can access it. (win_mkdtemp): Create a temporary directory using Windows APIs. * jit-playback.c: Do not chmod files in Windows. Use LoadLibrary, FreeLibrary and GetProcAddress instead of libdl. * jit-result.h, jit-result.c: Introduce result::handle_t to abstract over the types used for dynamic library handles. * jit-tempdir.c: Do not use mkdtemp() in Windows, use win_mkdtemp().
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure32
1 files changed, 19 insertions, 13 deletions
diff --git a/configure b/configure
index 3af6a530b9a..b7897446c70 100755
--- a/configure
+++ b/configure
@@ -6489,9 +6489,13 @@ $as_echo "$as_me: WARNING: GNAT is required to build $language" >&2;}
esac
# Disable jit if -enable-host-shared not specified
- case ${add_this_lang}:${language}:${host_shared} in
- yes:jit:no)
- # PR jit/64780: explicitly specify --enable-host-shared
+ # but not if building for Mingw
+ case $target in
+ *mingw*) ;;
+ *)
+ case ${add_this_lang}:${language}:${host_shared} in
+ yes:jit:no)
+ # PR jit/64780: explicitly specify --enable-host-shared
as_fn_error $? "
Enabling language \"jit\" requires --enable-host-shared.
@@ -6502,17 +6506,19 @@ If you want to build both the jit and the regular compiler, it is often
best to do this via two separate configure/builds, in separate
directories, to avoid imposing the performance cost of
--enable-host-shared on the regular compiler." "$LINENO" 5
- ;;
- all:jit:no)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-host-shared required to build $language" >&5
+ ;;
+ all:jit:no)
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-host-shared required to build $language" >&5
$as_echo "$as_me: WARNING: --enable-host-shared required to build $language" >&2;}
- add_this_lang=unsupported
- ;;
- *:jit:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
+ add_this_lang=unsupported
+ ;;
+ *:jit:no)
+ # Silently disable.
+ add_this_lang=unsupported
+ ;;
+ esac
+ ;;
+ esac
# Disable a language that is unsupported by the target.
case "${add_this_lang}: $unsupported_languages " in