Show error when build win32 version Ffmpeg in windows10,How solve it? - msys2

I build a win32 version ffmpeg for get the .dll and .lib file in windows10 follow the https://trac.ffmpeg.org/wiki/CompilationGuide/WinRT document, I excuted the command
../../../configure \
--toolchain=msvc \
--disable-programs \
--disable-d3d11va \
--disable-dxva2 \
--arch=x86 \
--enable-shared \
--enable-cross-compile \
--target-os=win32 \
--extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00" \
--extra-ldflags="-APPCONTAINER WindowsApp.lib" \
--prefix=../../../Build/Windows10/x86
everything work well,after that , I execute the command:
make
it show error:
\Users\LEE\Downloads\ffmpeg-snapshot\ffmpeg\Output\Windows10\x86\config.h: warning C4828: The file contains a character starting at offset 0x2da, which is invalid in the current source character set (code page 65001) .
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(59): error C2143: syntax error: missing ")" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(59): error C2143: syntax error: missing "{" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(60): warning C4228: Non-standard extension used: Ignore the qualifier after the comma in the declarator list
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(60): error C2143: syntax error: missing ";" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(61): error C2371: “IMFActivate”: redefinition; different base types
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\um\mfobjects.h(184): note: see the statement of "IMFActivate"
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(61): error C2143: syntax error: missing ";" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(61): warning C4142: "UINT32": benign redefinition of types
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\basetsd.h(81): note: see the statement of "UINT32"
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(61): error C2370: “UINT32”: redefinition; different storage class
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\basetsd.h(81): note: see the statement of "UINT32"
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(61): error C2059: syntax error: ")"
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(166): error C2143: syntax error: missing ")" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(166): error C2081: "MFT_REGISTER_TYPE_INFO": The name in the formal parameter table is illegal
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(166): error C2143: syntax error: missing "{" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(167): error C2143: syntax error: missing ";" (before "*")
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(168): error C2059: syntax error: "type"
c:\users\lee\downloads\ffmpeg-snapshot\ffmpeg\libavcodec\mf_utils.h(168): error C2059: syntax error: ")"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(54): error C2143: syntax error: missing ")" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(54): error C2143: syntax error: missing "{" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(55): warning C4228: Non-standard extension used: Ignore the qualifier after the comma in the declarator list
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(55): error C2143: syntax error: missing ";" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(56): error C2371: “IMFActivate”: redefinition; different base types
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\um\mfobjects.h(184): note: see the statement of "IMFActivate"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(56): error C2143: syntax error: missing ";" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(56): warning C4142: "UINT32": benign redefinition of types
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\basetsd.h(81): note: see the statement of "UINT32"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(56): error C2370: “UINT32”: redefinition; different storage class
C:\Program Files (x86)\Windows Kits\10\Include\10.0.14393.0\shared\basetsd.h(81): note: see the statement of "UINT32"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(56): error C2059: syntax error: ")"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(57): error C2054: "(" should be entered after "pnumMFTActivate"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(584): error C2143: syntax error: missing ")" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(584): error C2081: "MFT_REGISTER_TYPE_INFO": The name in the formal parameter table is illegal
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(584): error C2143: syntax error: missing "{" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(585): error C2143: syntax error: missing ";" (before "*")
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(586): error C2059: syntax error: "type"
C:/Users/LEE/Downloads/ffmpeg-snapshot/ffmpegbavcodec/mf_utils.c(587): error C2059: syntax error: ")"
make: *** [/c/Users/LEE/Downloads/ffmpeg-snapshot/ffmpeg/ffbuild/common.mak:67: libavcodec/mf_utils.o] Error 2
I don't know why, could you help me,thanks!

Related

Valgrind configure build script "Syntax Error" OSX Monterey - how to fix?

I'm trying to build Valgrind 3.19.0 on OSX monterey and when i run the configure script i get a syntax error at line 6594:
checking for diff -u... yes
./configure: line 6594: syntax error near unexpected token `newline'
./configure: line 6594: ` '''
This is the code sippet of the configure script where the error is occuring.
for as_dir in $PATH
do
IFS=$as_save_IFS
case $as_dir in #(((
''
as_dir=./ ;;
*/) ;;
*) as_dir=$as_dir/ ;;
Let me know if you need any more info.

Module Warning (from ./node_modules/eslint-loader/index.js): warning: Parsing error: Unexpected character "EOF" (prettier/prettier) at

I have a problem with compiling a vue module in Visual Studio code. During compilation It has always returned the same warning, although I'm using autoformat. I have already changed CRLF to LF, however it didn't help. Can somebody help me, please?
Module Warning (from ./node_modules/eslint-loader/index.js):
warning: Parsing error: Unexpected character "EOF" (prettier/prettier) at src\components\ViewEmployees.vue:34:2:
32 | }
33 | };
> 34 |
| ^
1 warning found.

Error: Syntax error at 'Boolean'; expected ')' in Artifactory OSS Puppet Module

Trying to use this puppet module, it breaks with syntax error:
Error: Syntax error at 'Boolean'; expected ')' at /etc/puppet/modules/artifactory/manifests/init.pp:6 on node artifactoryserver.openstacklocal
This is how I'm including it in the pp file:
node default { include '::artifactory' }
The line it refers is this one. Any idea of what I'm doing wrong?

Compiling Objective C files with gcc-4.7 on OSX with Apple core libraries such as Foundation.h

I'm somehow unable to compile Objective C files with GCC 4.7 that include any OSX core libraries such as:
#import <Foundation/Foundation.h>
The resulting error always results in a weird GCC output:
gcc -c -pipe -O2 -arch x86_64 -mmacosx-version-min=10.8 -Wall -W -I/usr/local/Cellar/qt/4.8.4/mkspecs/macx-g++ -I../TerrainFluid -I../TerrainFluid/external -I../TerrainFluid -I. ../TerrainFluid/external/osx_bundle.mm -o osx_bundle.o
In file included from
/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:123:0,
from ../TerrainFluid/external/osx_bundle.mm:24:
/System/Library/Frameworks/Foundation.framework/Headers/NSTask.h:69:24: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSTask.h:69:24: error: expected ')' before '^' token
In file included from /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:159:0,
from ../TerrainFluid/external/osx_bundle.mm:24:
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:36:15: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:36:15: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:37:39: error: expected type-specifier before 'NSUserScriptTaskCompletionHandler'
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:53:15: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:53:15: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:54:70: error: expected type-specifier before 'NSUserUnixTaskCompletionHandler'
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:68:15: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:68:15: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:69:82: error: expected type-specifier before 'NSUserAppleScriptTaskCompletionHandler'
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:86:15: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:86:15: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSUserScriptTask.h:87:72: error: expected type-specifier before 'NSUserAutomatorTaskCompletionHandler'
In file included from /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:160:0,
from ../TerrainFluid/external/osx_bundle.mm:24:
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:46:11: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:46:11: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:46:11: error: expected ';' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:47:11: error: expected unqualified-id before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:47:11: error: expected ')' before '^' token
/System/Library/Frameworks/Foundation.framework/Headers/NSXPCConnection.h:47:11: error: expected ';' before '^' token
make: *** [osx_bundle.o] Error 1
The way to solve this problem was for me to just use the Apple compiler for the Objective C files and g++ (4.7) for the rest of the code.
gcc -> /usr/bin/llvm-gcc
g++ -> /usr/local/bin/g++-4.7
I would have used clang for all the code but it doesn't support OpenMP yet and gcc-4.2 doesn't support C++11.
Here is the sample file I used (it's the Wildfire Games OSX Resource Bundle loader). I read in a blog post that Apple introduced a GCC blocker to stop compiles with GCC.
Now is there a way to compile the code with a non Apple GCC (such as GCC 4.7)? So far I was able to find no documentation on the matter other than to use the Apple compiler.
The very first error shows the problem.
#property (copy) void (^terminationHandler)(NSTask *) NS_AVAILABLE(10_7, NA);
this is the Blocks extension. Main line GCC does not implement support for blocks.

Error building mono in scratchbox [duplicate]

This question already has answers here:
Cross compile mono for arm
(2 answers)
Closed 8 years ago.
I tried to compile mono for arm in scratchbox on Ubuntu 11.10. But when I make install I got an error message.
[sbox-ARMEL:~] ./configure --enable-minimal=profiler,debug,logging,soft_debug --with-tls=--with-tls=__thread --with-monotouch=no --without-mcs-docs --disable-mono-debugger CFLAGS=-DARM_FPU_NONE --disable-mcs-build
[sbox-ARMEL:~] make
[sbox-ARMEL:~] make install
I get this error:
make[2]: Entering directory `/home/johannes/mono-2.10.2/mono/mini'
CC genmdesc-genmdesc.o
In file included from mini.h:39,
from genmdesc.c:9:
mini-unwind.h:106: error: expected declaration specifiers or '...' before 'mgreg_t'
mini-unwind.h:107: error: expected declaration specifiers or '...' before 'mgreg_t'
In file included from genmdesc.c:9:
mini.h:741: error: expected specifier-qualifier-list before 'mgreg_t'
In file included from genmdesc.c:9:
mini.h:1843: error: expected ')' before '*' token
mini.h:1848: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:1923: error: expected ')' before '*' token
mini.h:1924: error: expected ')' before '*' token
mini.h:1925: error: expected ')' before '*' token
mini.h:1926: error: expected ')' before '*' token
mini.h:1928: error: expected ')' before '*' token
mini.h:1930: error: expected ')' before '*' token
mini.h:1931: error: expected ')' before '*' token
mini.h:1932: error: expected ')' before '*' token
mini.h:1933: error: expected ')' before '*' token
mini.h:2061: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2084: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2092: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2093: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2094: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2096: error: expected ')' before '*' token
mini.h:2100: error: expected ')' before '*' token
mini.h:2101: error: expected ')' before '*' token
mini.h:2105: error: expected declaration specifiers or '...' before 'mgreg_t'
mini.h:2138: error: expected ')' before '*' token
mini.h:2148: error: expected declaration specifiers or '...' before 'mgreg_t'
make[2]: *** [genmdesc-genmdesc.o] Error 1
make[2]: Leaving directory `/home/johannes/mono-2.10.2/mono/mini'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/johannes/mono-2.10.2/mono'
make: *** [install-recursive] Error 1
Knows anyone this error or what I have done wrong?
Get source file from Git because your mini.h and mini-unwind.h file doesn't match the Git one.
https://github.com/mono/mono/blob/master/mono/mini/mini.h