You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to Cross-compile this library from linux to windows.
I modified the Makefile (ffmpeg30 part) as follow:
wget -O ffmpeg30.tar.bz2 http://ffmpeg.org/releases/ffmpeg-3.0.8.tar.bz2 mkdir ffmpeg30 && tar xf ffmpeg30.tar.bz2 -C ffmpeg30 --strip-components=1 && cd ffmpeg30 && ./configure --arch=x86 --target-os=mingw32 --cross-prefix=i686-w64-mingw32- --prefix=/usr/local --disable-debug --enable-pthreads --enable-nonfree --enable-gpl --disable-indev=jack && make -j6 && sudo make install
and it all works good but when I try to compile the example with:
GOOS=windows GOARCH=386 CGO_ENABLED=1 CXX=i686-w64-mingw32-g++ CC=i686-w64-mingw32-gcc go build -tags ffmpeg30
i get the following error:
# github.com/imkira/go-libav/avutil /usr/local/lib/libavutil.a(log.o):log.c:(.text+0x1da): undefined reference to 'pthread_mutex_lock' /usr/local/lib/libavutil.a(log.o):log.c:(.text+0x69a): undefined reference to 'pthread_mutex_unlock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x20): undefined reference to 'pthread_mutex_lock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x31): undefined reference to 'pthread_mutex_unlock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x81): undefined reference to 'pthread_mutex_destroy' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x767): undefined reference to 'pthread_mutex_init' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x7f3): undefined reference to 'pthread_mutex_destroy' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x81f): undefined reference to 'pthread_mutex_lock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x8a6): undefined reference to 'pthread_mutex_unlock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x956): undefined reference to 'pthread_mutex_unlock' /usr/local/lib/libavutil.a(buffer.o):buffer.c:(.text+0x968): undefined reference to 'pthread_mutex_unlock' collect2: error: ld returned 1 exit status
so I tried to modify the source adding some CFLAGS:
I tried to Cross-compile this library from linux to windows.
I modified the Makefile (ffmpeg30 part) as follow:
and it all works good but when I try to compile the example with:
i get the following error:
so I tried to modify the source adding some CFLAGS:
I didn't read it was supposed to work on windows nor i did read the opposit tho
The text was updated successfully, but these errors were encountered: