Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
dfa559bc
Commit
dfa559bc
authored
12 years ago
by
Ronald S. Bultje
Committed by
Martin Storsjö
12 years ago
Browse files
Options
Downloads
Patches
Plain Diff
configure: Add support for MSVC cl.exe/link.exe
Signed-off-by:
Martin Storsjö
<
martin@martin.st
>
parent
4fa661a8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
configure
+42
-0
42 additions, 0 deletions
configure
with
42 additions
and
0 deletions
configure
+
42
−
0
View file @
dfa559bc
...
@@ -2097,6 +2097,25 @@ EOF
...
@@ -2097,6 +2097,25 @@ EOF
die
"Sanity test failed."
die
"Sanity test failed."
fi
fi
msvc_flags
(){
for
flag
;
do
case
$flag
in
-fomit-frame-pointer
)
echo
-Oy
;;
-g
)
echo
-Z7
;;
-Wall
)
echo
-W4
-wd4244
-wd4127
-wd4018
-wd4389
\
-wd4146
-wd4057
-wd4204
-wd4706
-wd4305
\
-wd4152
-wd4324
-we4013
;;
-std
=
c99
)
;;
-fno-math-errno
)
;;
-fno-common
)
;;
-fno-signed-zeros
)
;;
-lz
)
echo
zlib.lib
;;
-l
*
)
echo
${
flag
#-l
}
.lib
;;
*
)
echo
$flag
;;
esac
done
}
pgi_flags
(){
pgi_flags
(){
for
flag
;
do
for
flag
;
do
case
$flag
in
case
$flag
in
...
@@ -2283,6 +2302,29 @@ probe_cc(){
...
@@ -2283,6 +2302,29 @@ probe_cc(){
_cflags_size
=
"-O2 -Munroll=c:1
$opt_common
"
_cflags_size
=
"-O2 -Munroll=c:1
$opt_common
"
_cflags_noopt
=
"-O1"
_cflags_noopt
=
"-O1"
_flags_filter
=
pgi_flags
_flags_filter
=
pgi_flags
elif
$_cc
2>&1 |
grep
-q
Microsoft
;
then
_type
=
msvc
_ident
=
$(
$cc
2>&1 |
head
-n1
)
_DEPCMD
=
'$(DEP$(1)) $(DEP$(1)FLAGS) $($(1)DEP_FLAGS) $< 2>&1 | awk '
\'
'/including/ { sub(/^.*file: */, ""); gsub(/\\/, "/"); if (!match($$0, / /)) print "$@:", $$0 }'
\'
' > $(@:.o=.d)'
_DEPFLAGS
=
'$(CPPFLAGS) $(CFLAGS) -showIncludes -Zs'
_cflags_speed
=
"-O2"
_cflags_size
=
"-O1"
# Nonstandard output options, to avoid msys path conversion issues, relies on wrapper to remap it
if
$_cc
2>&1 |
grep
-q
Linker
;
then
_ld_o
=
'-out $@'
else
_ld_o
=
'-Fe$@'
fi
_cc_o
=
'-Fo $@'
_flags_filter
=
msvc_flags
_ld_lib
=
'lib%.a'
_ld_path
=
'-libpath:'
_flags
=
'-nologo'
_cflags
=
'-D_USE_MATH_DEFINES -Dinline=__inline -FIstdlib.h -Dstrtoll=_strtoi64'
if
[
$pfx
=
hostcc
]
;
then
_cflags
=
"
$cflags
-Dsnprintf=_snprintf"
fi
disable aligned_stack
fi
fi
eval
${
pfx
}
_type
=
\$
_type
eval
${
pfx
}
_type
=
\$
_type
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment