Skip to content

Commit 8383534

Browse files
Merge pull request #52 from goblint/no_msvc
RFC: Remove support for MSVC
2 parents a3c91aa + d305573 commit 8383534

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+267
-1756
lines changed

CHANGES

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
## Unreleased
22
* Add ends to locations, allowing for ranges.
33
* Add additional expression locations to statements, etc.
4+
* Drop all support for MSVC
45

56
## Older versions
67

Makefile.in

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@ $(CILLY): $(CILLY_EXE_BIN) $(CILLYDIR)/Makefile
146146
$(MAKE) -C $(CILLYDIR)
147147

148148
# Create the machine dependency module
149-
# If the cl command cannot be run then the MSVC part will be identical to GCC
150149
.PHONY : machdep
151150
machdep: $(OBJDIR)/machdep.ml
152151
$(OBJDIR)/machdep.ml : src/machdep-ml.c configure.ac Makefile.in
@@ -204,15 +203,6 @@ $(OBJDIR)/machdep.ml : src/machdep-ml.c configure.ac Makefile.in
204203
@echo "let gcc = {" >>$@
205204
@$(OBJDIR)/machdep-ml.exe >>$@
206205
@echo "}" >>$@
207-
@if cl -D_MSVC $< -Fe$(OBJDIR)/machdep-ml.exe -Fo$(OBJDIR)/machdep-ml.obj ;then \
208-
echo "let hasMSVC = true" >>$@ ;\
209-
echo "let msvc = {" >>$@ ;\
210-
$(OBJDIR)/machdep-ml.exe >>$@ ;\
211-
echo "}" >>$@ \
212-
;else \
213-
echo "let hasMSVC = false" >>$@ ;\
214-
echo "let msvc = gcc" >> $@ \
215-
;fi
216206
@echo "let theMachine : mach ref = ref gcc" >>$@
217207

218208
$(CILLYDIR)/App/$(CILLYMOD).pm: $(CILLYDIR)/App/$(CILLYMOD).pm.in src/machdep-ml.c configure.ac Makefile.in

config.mk.in

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
# A bunch of variables -*- Mode: makefile -*-
2-
export HAS_MSVC=@HAS_MSVC@
32
export @DEFAULT_COMPILER@=1

configure

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -655,7 +655,6 @@ CIL_VERSION_MINOR
655655
CIL_VERSION_MAJOR
656656
DEFAULT_CIL_MODE
657657
DEFAULT_COMPILER
658-
HAS_MSVC
659658
EMUL
660659
LIBOBJS
661660
CYGPATH
@@ -3470,30 +3469,6 @@ test -n "$target_alias" &&
34703469
DEFAULT_COMPILER=_GNUCC
34713470
DEFAULT_CIL_MODE=GNUCC
34723471

3473-
# is the microsoft compiler available?
3474-
# hmm.. I think we should check the version or something, because
3475-
# sometimes people have Common Lisp's interpreter called 'cl' ..
3476-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for msvc cl.exe (optional)" >&5
3477-
printf %s "checking for msvc cl.exe (optional)... " >&6; }
3478-
# See if CC points to the MS compiler
3479-
if "$CC" 2>&1 | grep "Microsoft" >/dev/null; then
3480-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found, set as default" >&5
3481-
printf "%s\n" "found, set as default" >&6; }
3482-
HAS_MSVC=yes
3483-
DEFAULT_COMPILER=_MSVC
3484-
DEFAULT_CIL_MODE=MSVC
3485-
CFLAGS="-WX"
3486-
else
3487-
if cl 2>&1 | grep "Microsoft" >/dev/null ;then
3488-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found" >&5
3489-
printf "%s\n" "found" >&6; }
3490-
HAS_MSVC=yes
3491-
else
3492-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
3493-
printf "%s\n" "not found" >&6; }
3494-
HAS_MSVC=no
3495-
fi
3496-
fi
34973472

34983473
# ------------------- OCaml ----------------
34993474

@@ -5266,7 +5241,6 @@ rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
52665241
printf "%s\n" "$THREAD_IS_KEYWORD" >&6; }
52675242

52685243
# Does gcc add underscores to identifiers to make assembly labels?
5269-
# (I think MSVC always does)
52705244
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if gcc adds underscores to assembly labels." >&5
52715245
printf %s "checking if gcc adds underscores to assembly labels.... " >&6; }
52725246
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -6046,7 +6020,6 @@ printf "%s\n" "$real_type" >&6; }
60466020

60476021

60486022

6049-
60506023
# finish the configure script and generate various files; ./configure
60516024
# will apply variable substitutions to <filename>.in to generate <filename>;
60526025

@@ -7433,7 +7406,6 @@ fi
74337406
cat <<EOF
74347407
74357408
CIL configuration:
7436-
(optional) cl.exe found: HAS_MSVC $HAS_MSVC
74377409
gcc to use CC $CC
74387410
default compiler DEFAULT_COMPILER $DEFAULT_COMPILER
74397411
CIL version CIL_VERSION $CIL_VERSION

configure.ac

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -82,26 +82,6 @@ AC_EXEEXT
8282
DEFAULT_COMPILER=_GNUCC
8383
DEFAULT_CIL_MODE=GNUCC
8484

85-
# is the microsoft compiler available?
86-
# hmm.. I think we should check the version or something, because
87-
# sometimes people have Common Lisp's interpreter called 'cl' ..
88-
AC_MSG_CHECKING(for msvc cl.exe (optional))
89-
# See if CC points to the MS compiler
90-
if "$CC" 2>&1 | grep "Microsoft" >/dev/null; then
91-
AC_MSG_RESULT([found, set as default])
92-
HAS_MSVC=yes
93-
DEFAULT_COMPILER=_MSVC
94-
DEFAULT_CIL_MODE=MSVC
95-
CFLAGS="-WX"
96-
else
97-
if cl 2>&1 | grep "Microsoft" >/dev/null ;then
98-
AC_MSG_RESULT(found)
99-
HAS_MSVC=yes
100-
else
101-
AC_MSG_RESULT(not found)
102-
HAS_MSVC=no
103-
fi
104-
fi
10585

10686
# ------------------- OCaml ----------------
10787

@@ -155,7 +135,6 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([int main(int __thread) { return 0; }])],
155135
AC_MSG_RESULT($THREAD_IS_KEYWORD)
156136

157137
# Does gcc add underscores to identifiers to make assembly labels?
158-
# (I think MSVC always does)
159138
AC_MSG_CHECKING([if gcc adds underscores to assembly labels.])
160139
AC_LINK_IFELSE([AC_LANG_SOURCE([int main() { __asm__("jmp _main"); }])],
161140
UNDERSCORE_NAME=true,
@@ -186,7 +165,6 @@ CIL_CHECK_INTEGER_TYPE(wchar_t, TYPE_WCHAR_T)
186165
# names of the variables that get substituted in files; for example,
187166
# write @CIL_VERSION@ somewhere in a written file to get it substituted
188167
AC_SUBST(EMUL)
189-
AC_SUBST(HAS_MSVC)
190168
AC_SUBST(DEFAULT_COMPILER)
191169
AC_SUBST(DEFAULT_CIL_MODE)
192170
AC_SUBST(CIL_VERSION_MAJOR)
@@ -216,7 +194,6 @@ AC_OUTPUT
216194
cat <<EOF
217195
218196
CIL configuration:
219-
(optional) cl.exe found: HAS_MSVC $HAS_MSVC
220197
gcc to use CC $CC
221198
default compiler DEFAULT_COMPILER $DEFAULT_COMPILER
222199
CIL version CIL_VERSION $CIL_VERSION

0 commit comments

Comments
 (0)