Build tutorials with MAC

Ugly Face xuchangxue365812 at 126.com
Wed Jan 20 07:57:31 PST 2016


I am trying to build a tutorial on mac with gstreamer-1.0 (1.6.1).

I build it with cmd:
gcc  -Wall $(pkg-config --cflags gstreamer-1.0)
-I/usr/local/Cellar/gst-plugins-base/1.6.2/include/gstreamer-1.0/ -o gst c.c
$(pkg-config --libs gstreamer-1.0)
-L/usr/local/Cellar/gst-plugins-base/1.6.2/lib/ -v 

The output is:

Apple LLVM version 7.0.2 (clang-700.1.81)
Target: x86_64-apple-darwin15.3.0
Thread model: posix

"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang"
-cc1 -triple x86_64-apple-macosx10.11.0 -Wdeprecated-objc-isa-usage
-Werror=deprecated-objc-isa-usage -emit-obj -mrelax-all -disable-free
-disable-llvm-verifier -main-file-name c.c -mrelocation-model pic -pic-level
2 -mthread-model posix -mdisable-fp-elim -masm-verbose -munwind-tables
-target-cpu core2 -target-linker-version 253.9 -v -dwarf-column-info
-resource-dir
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/7.0.2
-isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk
-D _REENTRANT -I /usr/local/Cellar/gstreamer/1.6.2/include/gstreamer-1.0 -I
/usr/local/Cellar/gstreamer/1.6.2/lib/gstreamer-1.0/include -I
/usr/local/Cellar/glib/2.46.2/include/glib-2.0 -I
/usr/local/Cellar/glib/2.46.2/lib/glib-2.0/include -I
/usr/local/opt/gettext/include -I
/usr/local/Cellar/gst-plugins-base/1.6.2/include/gstreamer-1.0/ -Wall
-fdebug-compilation-dir /Users/Charlie/Documents/gstc -ferror-limit 19
-fmessage-length 0 -stack-protector 1 -mstackrealign -fblocks
-fobjc-runtime=macosx-10.11.0 -fencode-extended-block-signature
-fmax-type-align=16 -fdiagnostics-show-option -o
/var/folders/qr/110mk4kx05z1j6j0md1_h6y40000gn/T/c-50e8a5.o -x c c.c
clang -cc1 version 7.0.2 based upon LLVM 3.7.0svn default target
x86_64-apple-darwin15.3.0
ignoring nonexistent directory
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/local/include"
ignoring nonexistent directory
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/Library/Frameworks"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/Cellar/gstreamer/1.6.2/include/gstreamer-1.0
 /usr/local/Cellar/gstreamer/1.6.2/lib/gstreamer-1.0/include
 /usr/local/Cellar/glib/2.46.2/include/glib-2.0
 /usr/local/Cellar/glib/2.46.2/lib/glib-2.0/include
 /usr/local/opt/gettext/include
 /usr/local/Cellar/gst-plugins-base/1.6.2/include/gstreamer-1.0

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/7.0.2/include

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/System/Library/Frameworks
(framework directory)
End of search list.

"/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld"
-demangle -dynamic -arch x86_64 -macosx_version_min 10.11.0 -syslibroot
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk
-o gst -L/usr/local/Cellar/gstreamer/1.6.2/lib
-L/usr/local/Cellar/glib/2.46.2/lib -L/usr/local/opt/gettext/lib
-L/usr/local/Cellar/gst-plugins-base/1.6.2/lib/
/var/folders/qr/110mk4kx05z1j6j0md1_h6y40000gn/T/c-50e8a5.o -lgstreamer-1.0
-lgobject-2.0 -lglib-2.0 -lintl -lSystem
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/7.0.2/lib/darwin/libclang_rt.osx.a
Undefined symbols for architecture x86_64:
  "_gst_app_src_push_buffer", referenced from:
      _prepare_buffer in c-50e8a5.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see
invocation)


Could anyone give me any advice?

Thanks!

Charlie



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Build-tutorials-with-MAC-tp4675407.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list