在本地安装GTK-2时:目标' updateiconcache.o'失败的

发布于 2025-02-04 10:57:05 字数 7969 浏览 2 评论 0原文

我正在尝试在本地安装GTK 2.240 “>步骤。我从。接下来,我进行了以下操作:

setenv CPPFLAGS "-I/my/local/path/my_gtk/include"
setenv LDFLAGS "-L/my/local/path/my_gtk/lib"
setenv LD_LIBRARY_PATH "/my/local/path/my_gtk/lib"
setenv PKG_CONFIG_PATH "/my/local/path/my_gtk/lib/pkgconfig"

./configure --prefix=/my/local/path/my_gtk

之后,我跑了make并得到:

make  all-recursive
make[1]: Entering directory '/my/local/path/gtk+-2.24.20'
Making all in po
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/po'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/po'
Making all in po-properties
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/po-properties'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/po-properties'
Making all in gdk
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
cd .. && /bin/sh ./config.status gdk/gdkconfig.h
config.status: executing gdk/gdkconfig.h commands
config.status: gdk/gdkconfig.h is unchanged
echo timestamp > stamp-gc-h
make  all-recursive
make[3]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in x11
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk/x11'
make[4]: Nothing to be done for 'all'.
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk/x11'
Making all in .
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in tests
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk/tests'
make[4]: Nothing to be done for 'all'.
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk/tests'
make[3]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in gtk
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/gtk'
echo '#include <gtk/gtk.h>' > xgen-gtfsrc.c && \
  gcc -E -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"Gtk\" -DGTK_LIBDIR=\"/my/local/path/my_gtk/lib\" -DGTK_DATADIR=\"/my/local/path/my_gtk/share\" -DGTK_DATA_PREFIX=\"/my/local/path/my_gtk\" -DGTK_SYSCONFDIR=\"/my/local/path/my_gtk/etc\" -DGTK_VERSION=\"2.24.20\" -DGTK_BINARY_VERSION=\"2.10.0\" -DGTK_HOST=\"x86_64-unknown-linux-gnu\" -DGTK_COMPILATION -DGTK_PRINT_BACKENDS=\"file,cups\" -DGTK_PRINT_PREVIEW_COMMAND=\""evince --unlink-tempfile --preview --print-settings %s %f"\" -I.. -I../gtk -I.. -I../gdk -I../gdk -DGTK_DISABLE_DEPRECATED -DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED -DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -DG_DISABLE_CAST_CHECKS -pthread -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libpng12 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2     -DGTK_ENABLE_BROKEN  -I/my/local/path/my_gtk/include -DG_DISABLE_SINGLE_INCLUDES -DATK_DISABLE_SINGLE_INCLUDES -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_SINGLE_INCLUDES   -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall xgen-gtfsrc.c | \
  grep '^GType\s*g[td]k_[a-zA-Z0-9_]*_get_type\s*(void)' | \
  grep -o '\bg[td]k_[a-zA-Z0-9_]*_get_type\b' | \
  sed '{ s/^/*tp++ = /; s/$/();/; }' | \
  sort > xgen-gtf \
&& cp xgen-gtf gtktypefuncs.c && rm -f xgen-gtf
make  gtk-update-icon-cache 
make[3]: Entering directory '/my/local/path/gtk+-2.24.20/gtk'
gcc -DHAVE_CONFIG_H -I. -I.. -DG_LOG_DOMAIN=\"Gtk\" -DGTK_LIBDIR=\"/my/local/path/my_gtk/lib\" -DGTK_DATADIR=\"/my/local/path/my_gtk/share\" -DGTK_DATA_PREFIX=\"/my/local/path/my_gtk\" -DGTK_SYSCONFDIR=\"/my/local/path/my_gtk/etc\" -DGTK_VERSION=\"2.24.20\" -DGTK_BINARY_VERSION=\"2.10.0\" -DGTK_HOST=\"x86_64-unknown-linux-gnu\" -DGTK_COMPILATION -DGTK_PRINT_BACKENDS=\"file,cups\" -DGTK_PRINT_PREVIEW_COMMAND=\""evince --unlink-tempfile --preview --print-settings %s %f"\" -I.. -I../gtk -I.. -I../gdk -I../gdk -DGTK_DISABLE_DEPRECATED -DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED -DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -DG_DISABLE_CAST_CHECKS -pthread -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libpng12 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2      -I/my/local/path/my_gtk/include -DG_DISABLE_SINGLE_INCLUDES -DATK_DISABLE_SINGLE_INCLUDES -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_SINGLE_INCLUDES   -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall -MT updateiconcache.o -MD -MP -MF .deps/updateiconcache.Tpo -c -o updateiconcache.o updateiconcache.c
In file included from updateiconcache.c:56:0:
gtkiconcachevalidator.c: In function 'check_pixel_data':
gtkiconcachevalidator.c:166:7: error: unknown type name 'GdkPixdata'
       GdkPixdata data; 
       ^
gtkiconcachevalidator.c:168:7: warning: implicit declaration of function 'gdk_pixdata_deserialize' [-Wimplicit-function-declaration]
       check ("pixel data", gdk_pixdata_deserialize (&data, length,
       ^
updateiconcache.c: At top level:
updateiconcache.c:168:3: error: unknown type name 'GdkPixdata'
   GdkPixdata pixdata;
   ^
updateiconcache.c: In function 'maybe_cache_image_data':
updateiconcache.c:476:7: error: unknown type name 'GdkPixbuf'
       GdkPixbuf *pixbuf;
       ^
updateiconcache.c:515:4: warning: implicit declaration of function 'gdk_pixbuf_new_from_file' [-Wimplicit-function-declaration]
    pixbuf = gdk_pixbuf_new_from_file (path, NULL);
    ^
updateiconcache.c:515:11: warning: assignment makes pointer from integer without a cast [enabled by default]
    pixbuf = gdk_pixbuf_new_from_file (path, NULL);
           ^
updateiconcache.c:519:8: warning: implicit declaration of function 'gdk_pixdata_from_pixbuf' [-Wimplicit-function-declaration]
        gdk_pixdata_from_pixbuf (&idata->pixdata, pixbuf, FALSE);
        ^
updateiconcache.c:520:36: error: request for member 'length' in something not a structure or union
        idata->size = idata->pixdata.length + 8;
                                    ^
updateiconcache.c: In function 'write_image_data':
updateiconcache.c:824:3: error: unknown type name 'GdkPixdata'
   GdkPixdata *pixdata = &image_data->pixdata;
   ^
updateiconcache.c:830:3: warning: implicit declaration of function 'gdk_pixdata_serialize' [-Wimplicit-function-declaration]
   s = gdk_pixdata_serialize (pixdata, &len);
   ^
updateiconcache.c:830:5: warning: assignment makes pointer from integer without a cast [enabled by default]
   s = gdk_pixdata_serialize (pixdata, &len);
     ^
updateiconcache.c: In function 'write_bucket':
updateiconcache.c:1116:11: warning: variable 'tmp' set but not used [-Wunused-but-set-variable]
       int tmp;
           ^
updateiconcache.c: In function 'main':
updateiconcache.c:1764:3: warning: implicit declaration of function 'g_type_init' [-Wimplicit-function-declaration]
   g_type_init ();
   ^
Makefile:2902: recipe for target 'updateiconcache.o' failed
make[3]: *** [updateiconcache.o] Error 1
make[3]: Leaving directory '/my/local/path/gtk+-2.24.20/gtk'
Makefile:5697: recipe for target 'gtkbuiltincache.h' failed
make[2]: *** [gtkbuiltincache.h] Error 2
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/gtk'
Makefile:718: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/my/local/path/gtk+-2.24.20'
Makefile:609: recipe for target 'all' failed
make: *** [all] Error 2

我将SUSE SLES12用作我的操作系统。我认为由于target“ updateiconcache.o”的配方失败,它失败了。如何解决?

I'm trying to install GTK 2.24.20 locally, using those steps. I downloaded the tar from here. Next I did the following:

setenv CPPFLAGS "-I/my/local/path/my_gtk/include"
setenv LDFLAGS "-L/my/local/path/my_gtk/lib"
setenv LD_LIBRARY_PATH "/my/local/path/my_gtk/lib"
setenv PKG_CONFIG_PATH "/my/local/path/my_gtk/lib/pkgconfig"

./configure --prefix=/my/local/path/my_gtk

After that I ran make and got:

make  all-recursive
make[1]: Entering directory '/my/local/path/gtk+-2.24.20'
Making all in po
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/po'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/po'
Making all in po-properties
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/po-properties'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/po-properties'
Making all in gdk
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
cd .. && /bin/sh ./config.status gdk/gdkconfig.h
config.status: executing gdk/gdkconfig.h commands
config.status: gdk/gdkconfig.h is unchanged
echo timestamp > stamp-gc-h
make  all-recursive
make[3]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in x11
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk/x11'
make[4]: Nothing to be done for 'all'.
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk/x11'
Making all in .
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk'
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in tests
make[4]: Entering directory '/my/local/path/gtk+-2.24.20/gdk/tests'
make[4]: Nothing to be done for 'all'.
make[4]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk/tests'
make[3]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/gdk'
Making all in gtk
make[2]: Entering directory '/my/local/path/gtk+-2.24.20/gtk'
echo '#include <gtk/gtk.h>' > xgen-gtfsrc.c && \
  gcc -E -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"Gtk\" -DGTK_LIBDIR=\"/my/local/path/my_gtk/lib\" -DGTK_DATADIR=\"/my/local/path/my_gtk/share\" -DGTK_DATA_PREFIX=\"/my/local/path/my_gtk\" -DGTK_SYSCONFDIR=\"/my/local/path/my_gtk/etc\" -DGTK_VERSION=\"2.24.20\" -DGTK_BINARY_VERSION=\"2.10.0\" -DGTK_HOST=\"x86_64-unknown-linux-gnu\" -DGTK_COMPILATION -DGTK_PRINT_BACKENDS=\"file,cups\" -DGTK_PRINT_PREVIEW_COMMAND=\""evince --unlink-tempfile --preview --print-settings %s %f"\" -I.. -I../gtk -I.. -I../gdk -I../gdk -DGTK_DISABLE_DEPRECATED -DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED -DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -DG_DISABLE_CAST_CHECKS -pthread -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libpng12 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2     -DGTK_ENABLE_BROKEN  -I/my/local/path/my_gtk/include -DG_DISABLE_SINGLE_INCLUDES -DATK_DISABLE_SINGLE_INCLUDES -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_SINGLE_INCLUDES   -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall xgen-gtfsrc.c | \
  grep '^GType\s*g[td]k_[a-zA-Z0-9_]*_get_type\s*(void)' | \
  grep -o '\bg[td]k_[a-zA-Z0-9_]*_get_type\b' | \
  sed '{ s/^/*tp++ = /; s/$/();/; }' | \
  sort > xgen-gtf \
&& cp xgen-gtf gtktypefuncs.c && rm -f xgen-gtf
make  gtk-update-icon-cache 
make[3]: Entering directory '/my/local/path/gtk+-2.24.20/gtk'
gcc -DHAVE_CONFIG_H -I. -I.. -DG_LOG_DOMAIN=\"Gtk\" -DGTK_LIBDIR=\"/my/local/path/my_gtk/lib\" -DGTK_DATADIR=\"/my/local/path/my_gtk/share\" -DGTK_DATA_PREFIX=\"/my/local/path/my_gtk\" -DGTK_SYSCONFDIR=\"/my/local/path/my_gtk/etc\" -DGTK_VERSION=\"2.24.20\" -DGTK_BINARY_VERSION=\"2.10.0\" -DGTK_HOST=\"x86_64-unknown-linux-gnu\" -DGTK_COMPILATION -DGTK_PRINT_BACKENDS=\"file,cups\" -DGTK_PRINT_PREVIEW_COMMAND=\""evince --unlink-tempfile --preview --print-settings %s %f"\" -I.. -I../gtk -I.. -I../gdk -I../gdk -DGTK_DISABLE_DEPRECATED -DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED -DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED -pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include  -DG_DISABLE_CAST_CHECKS -pthread -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libdrm -I/usr/include/libpng12 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/freetype2      -I/my/local/path/my_gtk/include -DG_DISABLE_SINGLE_INCLUDES -DATK_DISABLE_SINGLE_INCLUDES -DGDK_PIXBUF_DISABLE_SINGLE_INCLUDES -DGTK_DISABLE_SINGLE_INCLUDES   -DGDK_PIXBUF_DISABLE_DEPRECATED -g -O2 -Wall -MT updateiconcache.o -MD -MP -MF .deps/updateiconcache.Tpo -c -o updateiconcache.o updateiconcache.c
In file included from updateiconcache.c:56:0:
gtkiconcachevalidator.c: In function 'check_pixel_data':
gtkiconcachevalidator.c:166:7: error: unknown type name 'GdkPixdata'
       GdkPixdata data; 
       ^
gtkiconcachevalidator.c:168:7: warning: implicit declaration of function 'gdk_pixdata_deserialize' [-Wimplicit-function-declaration]
       check ("pixel data", gdk_pixdata_deserialize (&data, length,
       ^
updateiconcache.c: At top level:
updateiconcache.c:168:3: error: unknown type name 'GdkPixdata'
   GdkPixdata pixdata;
   ^
updateiconcache.c: In function 'maybe_cache_image_data':
updateiconcache.c:476:7: error: unknown type name 'GdkPixbuf'
       GdkPixbuf *pixbuf;
       ^
updateiconcache.c:515:4: warning: implicit declaration of function 'gdk_pixbuf_new_from_file' [-Wimplicit-function-declaration]
    pixbuf = gdk_pixbuf_new_from_file (path, NULL);
    ^
updateiconcache.c:515:11: warning: assignment makes pointer from integer without a cast [enabled by default]
    pixbuf = gdk_pixbuf_new_from_file (path, NULL);
           ^
updateiconcache.c:519:8: warning: implicit declaration of function 'gdk_pixdata_from_pixbuf' [-Wimplicit-function-declaration]
        gdk_pixdata_from_pixbuf (&idata->pixdata, pixbuf, FALSE);
        ^
updateiconcache.c:520:36: error: request for member 'length' in something not a structure or union
        idata->size = idata->pixdata.length + 8;
                                    ^
updateiconcache.c: In function 'write_image_data':
updateiconcache.c:824:3: error: unknown type name 'GdkPixdata'
   GdkPixdata *pixdata = &image_data->pixdata;
   ^
updateiconcache.c:830:3: warning: implicit declaration of function 'gdk_pixdata_serialize' [-Wimplicit-function-declaration]
   s = gdk_pixdata_serialize (pixdata, &len);
   ^
updateiconcache.c:830:5: warning: assignment makes pointer from integer without a cast [enabled by default]
   s = gdk_pixdata_serialize (pixdata, &len);
     ^
updateiconcache.c: In function 'write_bucket':
updateiconcache.c:1116:11: warning: variable 'tmp' set but not used [-Wunused-but-set-variable]
       int tmp;
           ^
updateiconcache.c: In function 'main':
updateiconcache.c:1764:3: warning: implicit declaration of function 'g_type_init' [-Wimplicit-function-declaration]
   g_type_init ();
   ^
Makefile:2902: recipe for target 'updateiconcache.o' failed
make[3]: *** [updateiconcache.o] Error 1
make[3]: Leaving directory '/my/local/path/gtk+-2.24.20/gtk'
Makefile:5697: recipe for target 'gtkbuiltincache.h' failed
make[2]: *** [gtkbuiltincache.h] Error 2
make[2]: Leaving directory '/my/local/path/gtk+-2.24.20/gtk'
Makefile:718: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/my/local/path/gtk+-2.24.20'
Makefile:609: recipe for target 'all' failed
make: *** [all] Error 2

I'm using SUSE SLES12 as my OS. I think it fails due to recipe for target 'updateiconcache.o' failed. How it can be solved?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

郁金香雨 2025-02-11 10:57:05

因为GDK添加-dgdk_pixbuf_disable_disable_deprept默认情况下,它将禁用GDK-pixbuf加载&lt; gdk-pixbuf/gdk-pixbuf.h&gt; gt;

because gdk add -DGDK_PIXBUF_DISABLE_DEPRECATED by default, which will disable gdk-pixbuf for loading <gdk-pixbuf/gdk-pixbuf.h>

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文