輸入優惠碼現折100元
首頁 / LinuxDev / MinGW gdk-pixbuf-2.22.1 make error

MinGW gdk-pixbuf-2.22.1 make error

/bin/sh ../../libtool  –tag=CC   –mode=compile gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I../.. -I../.. -I../..  -mms-bitfields -IC://include/glib-2.0 -IC://lib/glib-2.0/include -IC://include/libpng14     -DG_DISABLE_SINGLE_INCLUDES -I//include  -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall -mms-bitfields -MT pixops.lo -MD -MP -MF .deps/pixops.Tpo -c -o pixops.lo pixops.c
libtool: compile:  gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I../.. -I../.. -I../.. -mms-bitfields -IC:/MinGW/include/glib-2.0 -IC:/MinGW/lib/glib-2.0/include -IC:/MinGW/include/libpng14  -DG_DISABLE_SINGLE_INCLUDES -I/mingw/include -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall -mms-bitfields -MT pixops.lo -MD -MP -MF .deps/pixops.Tpo -c pixops.c  -DDLL_EXPORT -DPIC -o .libs/pixops.o
libtool: compile:  gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I../.. -I../.. -I../.. -mms-bitfields -IC:/MinGW/include/glib-2.0 -IC:/MinGW/lib/glib-2.0/include -IC:/MinGW/include/libpng14  -DG_DISABLE_SINGLE_INCLUDES -I/mingw/include -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall -mms-bitfields -MT pixops.lo -MD -MP -MF .deps/pixops.Tpo -c pixops.c  -DDLL_EXPORT -DPIC -o .libs/pixops.o
gcc.exe: : Invalid argument
make[4]: *** [pixops.lo] Error 1

上述的編譯錯誤,奮鬥了兩天終於解決了,不是自己改錯的,而是上天幫助我找到Building Evolution on Windows的這一段:『

for Win32 can be found on ftp.gnome.org, too, in http://ftp.gnome.org/pub/gnome/binaries/win32/dependencies/.

To work around a bug in bash, you need to create a file pkg-config.sh somewhere with the contents:

#!/bin/sh
if pkg-config "$@" > /dev/null 2>&1 ; then
res=true
else
res=false
fi
pkg-config "$@" | tr -d \\r && $res

And then set the environment variable PKG_CONFIG=/path/to/that/pkg-config.sh

也就是說,在MSYS裡,會有錯誤,所以需要新增一個pkg-config.sh的檔案,然後設定PKG_CONFIG,賓果,醬就對了,我把pkg-config.sh放在/mingw/bin下,設定PKG_CONFIG=/mingw/bin/pkg-config.sh,然後編譯這個套件就成功了,感謝神,又過一關了!

Print Friendly, PDF & Email
馬上成為工作達人的Fans

About ㄚ琪

工作達人Fun Taiwan的創辦者及總編,可以在這裡更認識他。

發表迴響

你的電子郵件位址並不會被公開。 Required fields are marked *

*

這個網站採用 Akismet 服務減少垃圾留言。進一步瞭解 Akismet 如何處理網站訪客的留言資料

Scroll To Top