由 訪客 » 週五 2月 15, 2008 12:10 am
請教 PcMan 大哥
在 SuSE 10.1(含)之前的版本編譯出現錯誤訊息如下
if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../src/mime-type -I../src/compat -I../src/ptk -I../src/vfs -I../src/libmd5-rfc -I../src/desktop -I../src/inotify -DPACKAGE_DATA_DIR=\""/usr/share/pcmanfm"\" -DPACKAGE_LOCALE_DIR=\""/usr/share/locale"\" -pthread -I/usr/include/cairo -I/usr/include/freetype2 -I/usr/X11R6/include -I/usr/include/libpng12 -I/usr/include/startup-notification-1.0 -I/opt/gnome/include/gtk-2.0 -I/opt/gnome/lib/gtk-2.0/include -I/opt/gnome/include/atk-1.0 -I/opt/gnome/include/pango-1.0 -I/opt/gnome/include/glib-2.0 -I/opt/gnome/lib/glib-2.0/include -DDBUS_API_SUBJECT_TO_CHANGE -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/hal -I/opt/gnome/include/glib-2.0 -I/opt/gnome/lib/glib-2.0/include -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64 -g -O2 -MT mime-action.o -MD -MP -MF ".deps/mime-action.Tpo" -c -o mime-action.o `test -f 'mime-type/mime-action.c' || echo './'`mime-type/mime-action.c; \
then mv -f ".deps/mime-action.Tpo" ".deps/mime-action.Po"; else rm -f ".deps/mime-action.Tpo"; exit 1; fi
mime-type/mime-action.c: In function 'mime_type_locate_desktop_file':
mime-type/mime-action.c:416: warning: passing argument 3 of '_locate_desktop_file' discards qualifiers from pointer target type
mime-type/mime-action.c:417: warning: passing argument 3 of 'data_dir_foreach' discards qualifiers from pointer target type
if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../src/mime-type -I../src/compat -I../src/ptk -I../src/vfs -I../src/libmd5-rfc -I../src/desktop -I../src/inotify -DPACKAGE_DATA_DIR=\""/usr/share/pcmanfm"\" -DPACKAGE_LOCALE_DIR=\""/usr/share/locale"\" -pthread -I/usr/include/cairo -I/usr/include/freetype2 -I/usr/X11R6/include -I/usr/include/libpng12 -I/usr/include/startup-notification-1.0 -I/opt/gnome/include/gtk-2.0 -I/opt/gnome/lib/gtk-2.0/include -I/opt/gnome/include/atk-1.0 -I/opt/gnome/include/pango-1.0 -I/opt/gnome/include/glib-2.0 -I/opt/gnome/lib/glib-2.0/include -DDBUS_API_SUBJECT_TO_CHANGE -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/hal -I/opt/gnome/include/glib-2.0 -I/opt/gnome/lib/glib-2.0/include -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64 -g -O2 -MT mime-cache.o -MD -MP -MF ".deps/mime-cache.Tpo" -c -o mime-cache.o `test -f 'mime-type/mime-cache.c' || echo './'`mime-type/mime-cache.c; \
then mv -f ".deps/mime-cache.Tpo" ".deps/mime-cache.Po"; else rm -f ".deps/mime-cache.Tpo"; exit 1; fi
mime-type/mime-cache.c: In function 'mime_cache_new':
mime-type/mime-cache.c:62: error: expected expression before 'MimeCache'
mime-type/mime-cache.c:62: warning: assignment makes pointer from integer without a cast
mime-type/mime-cache.c: In function 'mime_cache_free':
mime-type/mime-cache.c:86: error: expected expression before 'MimeCache'
make[2]: *** [mime-cache.o] Error 1
make[2]: Leaving directory `/usr/src/packages/BUILD/pcmanfm-0.3.5.8/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/packages/BUILD/pcmanfm-0.3.5.8'
make: *** [all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.63488 (%build)
是 gcc 版本問題嗎?
openSUSE 10.2 10.3 皆正常編譯使用