Linux的现状真是一堆散沙,编译个GNOMEGames痛苦得吐血不止

想学习下GNOME Games中特别是俄罗斯方块(GnomeTetris)的按键控制,下载了gnome-games-2.25.4.tar.bz2,心血来潮,想编译一下看看,结果踏上长长的吐血之路,可怜...
最终结果,还是卡在GTK的编译上  :-(

花了整整一下午来搜索网络/下载各关联源程序包/编译/换版本...
首先,是GTK的编译需要 Glib, ATK, Pango, Cairo; 看似不多,然后是垃圾的Cairo需要 Pixman, libpng, freetype, libxml...

沙子的海洋,里面还有狗屎,要把散沙熔合成哪怕几块玻璃,都是不容易的事情;
感叹那些维护Linux发行版的弟兄们,辛苦了!
不过这种关联性与频繁的版本变动性,还将让人深陷其中,无边无际的苦海啊
在此,也鄙视下CSDN里面的一些专家,袁老师就算一个,整天喊Linux多好,何苦呢?
哪位仁兄,不看手册,直接去我列出的网站挑选各版本下载来编译,半天能搞定的,I服了U!

A. ===========================
glib-2.19.4.tar.bz2    http://ftp.gnome.org/pub/gnome/sources/
    >> Built & installed!

B. ===========================
atk-1.25.2.tar.gz    http://ftp.gnome.org/pub/gnome/sources/  
    >> Built & installed!

C. ==========================
pango-1.22.4.tar.bz2    http://ftp.gnome.org/pub/gnome/sources/
    >> Built & installed!
    
D. ==========================
D-a) cairo-1.7.2.tar.gz http://cairographics.org/releases/
    1) pixman-0.11.8.tar.gz  >> Built & installed!
    2) libpng-1.2.34.tar.gz  >> Built & installed! (www.libpng.org/pub/png/libpng.html)

    "configure: error: Cairo requires at least one font backend.
    Please install freetype and fontconfig, then try again:
      http://freetype.org/    http://fontconfig.org/"
    3) freetype-2.3.7.tar.gz >> Built & installed!    
        "rmdir: 删除 “/usr/local/include/freetype2/freetype/internal” 失败: 没有该文件或目录"  ---Only warning!


    cairoint.h:942:2: error: #error No font backends are available.
    make[1]: *** [libcairo_la-cairo.lo] 错误 1

    4) fontconfig-2.6.0.tar.-1.22.4.tar.bz2 /gz    >> Built & installed!
        http://fontconfig.org/release/
        "checking for LIBXML2... configure: error: Package requirements (libxml-2.0 >= 2.6) were not met:"

    4.1) libxml2-dev >>Installed via Synaptic!


cairo-user-font.c:38:37: error: cairo-user-font-private.h: 没有该文件或目录
cairo-user-font.c:450: 警告: ‘_cairo_font_face_is_user’先前没有原型
make[2]: *** [libcairo_la-cairo-user-font.lo] 错误 1
make[2]:正在离开目录 `/usr/share/cairo-1.7.2/src'
<<<<<Failed here !!!>>>>>>

------------------------------------------------
D-b)cairo-1.8.6.tar.gz    http://cairographics.org/releases/

checking whether cairo's image surface backend feature could be enabled... no (requires pixman-1 >= 0.12.0 http://cairographics.org/releases/)
configure: error: mandatory image surface backend feature could not be enabled

    5) pixman-0.12.0.tar.gz  >> Built & installed!
    OK!

E. =====================================
gtk+-2.15.0    http://ftp.gnome.org/pub/gnome/sources/

    checking for BASE_DEPENDENCIES... configure: error: Package requirements (glib-2.0 >= 2.17.6    atk >= 1.13.0    pango >= 1.20    cairo >= 1.6) were not met:


    configure: error:
    *** Checks for TIFF loader failed. You can build without it by passing
    *** --without-libtiff to configure but some programs using GTK+ may
    *** not work properly

    *** Checks for JPEG2000 loader failed. You can build without it by passing
    *** --without-libjasper to configure
 
 ./configure --without-libtiff --without-libjpeg --without-libjasper
 
configure: error: *** libX11 not found. Check 'config.log' for more details.
<<<<<Failed here !!!>>>>>>

阅读更多

【50分求指教】Linux现状真是一堆散沙,编译GNOMEGames苦得吐血不止

01-12

http://blog.csdn.net/Tycool/archive/2009/01/12/3761487.aspxrnrn想学习下GNOME Games中特别是俄罗斯方块(GnomeTetris)的按键控制,下载了gnome-games-2.25.4.tar.bz2,心血来潮,想编译一下看看,结果踏上长长的吐血之路,可怜...rn最终结果,还是卡在GTK的编译上 :-(rnrn花了整整一下午来搜索网络/下载各关联源程序包/编译/换版本...rn首先,是GTK的编译需要 Glib, ATK, Pango, Cairo; 看似不多,然后是垃圾的Cairo需要 Pixman, libpng, freetype, libxml...rnrn沙子的海洋,里面还有狗屎,要把散沙熔合成哪怕几块玻璃,都是不容易的事情;rn感叹那些维护Linux发行版的弟兄们,辛苦了!rn不过这种关联性与频繁的版本变动性,还将让人深陷其中,无边无际的苦海啊rn在此,也鄙视下CSDN里面的一些专家,袁老师就算一个,整天喊Linux多好,何苦呢?rn哪位仁兄,不看手册,直接去我列出的网站挑选各版本下载来编译,半天能搞定的,I服了U!rnrnA. ===========================rnglib-2.19.4.tar.bz2 http://ftp.gnome.org/pub/gnome/sources/rn >> Built & installed!rnrnB. ===========================rnatk-1.25.2.tar.gz http://ftp.gnome.org/pub/gnome/sources/ rn >> Built & installed!rnrnC. ==========================rnpango-1.22.4.tar.bz2 http://ftp.gnome.org/pub/gnome/sources/rn >> Built & installed!rn rnD. ==========================rnD-a) cairo-1.7.2.tar.gz http://cairographics.org/releases/rn 1) pixman-0.11.8.tar.gz >> Built & installed!rn 2) libpng-1.2.34.tar.gz >> Built & installed! (www.libpng.org/pub/png/libpng.html)rnrn "configure: error: Cairo requires at least one font backend.rn Please install freetype and fontconfig, then try again:rn http://freetype.org/ http://fontconfig.org/"rn 3) freetype-2.3.7.tar.gz >> Built & installed! rn "rmdir: 删除 “/usr/local/include/freetype2/freetype/internal” 失败: 没有该文件或目录" ---Only warning!rnrnrn cairoint.h:942:2: error: #error No font backends are available.rn make[1]: *** [libcairo_la-cairo.lo] 错误 1rnrn 4) fontconfig-2.6.0.tar.-1.22.4.tar.bz2 /gz >> Built & installed!rn http://fontconfig.org/release/rn "checking for LIBXML2... configure: error: Package requirements (libxml-2.0 >= 2.6) were not met:"rnrn 4.1) libxml2-dev >>Installed via Synaptic!rnrnrncairo-user-font.c:38:37: error: cairo-user-font-private.h: 没有该文件或目录rncairo-user-font.c:450: 警告: ‘_cairo_font_face_is_user’先前没有原型rnmake[2]: *** [libcairo_la-cairo-user-font.lo] 错误 1rnmake[2]:正在离开目录 `/usr/share/cairo-1.7.2/src'rn<<<<>>>>>rnrn------------------------------------------------rnD-b)cairo-1.8.6.tar.gz http://cairographics.org/releases/rnrnchecking whether cairo's image surface backend feature could be enabled... no (requires pixman-1 >= 0.12.0 http://cairographics.org/releases/)rnconfigure: error: mandatory image surface backend feature could not be enabledrnrn 5) pixman-0.12.0.tar.gz >> Built & installed!rn OK!rnrnE. =====================================rngtk+-2.15.0 http://ftp.gnome.org/pub/gnome/sources/rnrn checking for BASE_DEPENDENCIES... configure: error: Package requirements (glib-2.0 >= 2.17.6 atk >= 1.13.0 pango >= 1.20 cairo >= 1.6) were not met:rnrnrn configure: error:rn *** Checks for TIFF loader failed. You can build without it by passingrn *** --without-libtiff to configure but some programs using GTK+ mayrn *** not work properlyrnrn *** Checks for JPEG2000 loader failed. You can build without it by passingrn *** --without-libjasper to configurern rn ./configure --without-libtiff --without-libjpeg --without-libjasperrn rnconfigure: error: *** libX11 not found. Check 'config.log' for more details.rn<<<<>>>>>

吐血送分!编译下列代码出现一堆错误!

04-10

#include "stdio.h" rn#include "tchar.h" rn#include "windows.h" rn#include "setupapi.h"rnrn#pragma comment (lib,"setupapi")rnrn#define UnknownDevice TEXT("")rnrnHDEVINFO hDevInfo = 0;rnrnrnBOOL StateChange(DWORD NewState, DWORD SelectedItem,HDEVINFO hDevInfo)rnrn SP_PROPCHANGE_PARAMS PropChangeParams = sizeof(SP_CLASSINSTALL_HEADER);rn SP_DEVINFO_DATA DeviceInfoData = sizeof(SP_DEVINFO_DATA);rn HCURSOR hCursor;rnrn //rn // This may take a while :^(rn //rn hCursor = SetCursor(LoadCursor(NULL, IDC_WAIT));rnrn //rn // Get a handle to the Selected Item.rn //rn if (!SetupDiEnumDeviceInfo(hDevInfo,SelectedItem,&DeviceInfoData))rn rn printf("EnumDeviceInfo");rn return FALSE;rn rnrn //rn // Set the PropChangeParams structure.rn //rn PropChangeParams.ClassInstallHeader.InstallFunction = DIF_PROPERTYCHANGE;rn PropChangeParams.Scope = DICS_FLAG_GLOBAL;rn PropChangeParams.StateChange = NewState; rnrn if (!SetupDiSetClassInstallParams(hDevInfo,rn &DeviceInfoData,rn (SP_CLASSINSTALL_HEADER *)&PropChangeParams,rn sizeof(PropChangeParams)))rn rn printf("SetClassInstallParams");rn SetCursor(hCursor);rn return FALSE;rn rnrn //rn // Call the ClassInstaller and perform the change.rn //rn if (!SetupDiCallClassInstaller(DIF_PROPERTYCHANGE,rn hDevInfo,rn &DeviceInfoData))rn rn printf("SetClassInstallParams");rn SetCursor(hCursor);rn return TRUE;rn rnrn SetCursor(hCursor);rn return TRUE;rnrnrnrnBOOL IsClassNet( GUID * ClassGuid )rnrn #define MAX_NUM 50rnrn HKEY hKeyClass;rn LONG lRet;rn char ClassType[MAX_NUM];rn char NetClass[MAX_NUM] = "Net";rn DWORD dwLength = MAX_NUM,dwType = REG_SZ;rn rn if (hKeyClass = SetupDiOpenClassRegKey(ClassGuid,KEY_READ))rn rn lRet = RegQueryValueEx(hKeyClass, rn TEXT("Class"), rn NULL, &dwType, LPBYTE(ClassType), &dwLength);rn RegCloseKey(hKeyClass);rnrn if (lRet != ERROR_SUCCESS)rn return FALSE;rnrn if (!strcmp(ClassType,NetClass))rn return TRUE;rn rnrn return FALSE;rnrnrnint main(int argc, char* argv[])rnrn if (INVALID_HANDLE_VALUE == (hDevInfo = rn SetupDiGetClassDevs(NULL,NULL,0,rn DIGCF_PRESENT|DIGCF_ALLCLASSES)))rn rn printf("GetClassDevs");rn return 0;rn rnrn DWORD i, Status, Problem;rn SP_DEVINFO_DATA DeviceInfoData = sizeof(SP_DEVINFO_DATA);rnrn HKEY hKeyClass;rn char DeviceName[200];rn for (i=0;SetupDiEnumDeviceInfo(hDevInfo,i,&DeviceInfoData);i++)rn rn if (IsClassNet(&DeviceInfoData.ClassGuid))rn rn //printf(" the class's index is %d\n",i);rn rnrn //DICS_DISABLE-->禁用网络rn //DICS_ENABLE--->恢复网络rn if (StateChange(DICS_ENABLE,i,hDevInfo))rn printf(".");rn //printf("NetWork %s", (DICS_ENABLE)?"enabled":"disabled");rnrn rn rnrn return 0;rnrnrnrnCompiling...rnnetcardctrl.crne:\development\device control\netcardctrl.c(81) : error C2063: 'LPBYTE' : not a functionrne:\development\device control\netcardctrl.c(104) : error C2275: 'DWORD' : illegal use of this type as an expressionrn e:\win2k programfiles\vc98\include\windef.h(141) : see declaration of 'DWORD'rne:\development\device control\netcardctrl.c(104) : error C2146: syntax error : missing ';' before identifier 'i'rne:\development\device control\netcardctrl.c(104) : error C2065: 'i' : undeclared identifierrne:\development\device control\netcardctrl.c(104) : error C2065: 'Status' : undeclared identifierrne:\development\device control\netcardctrl.c(104) : error C2065: 'Problem' : undeclared identifierrne:\development\device control\netcardctrl.c(105) : error C2275: 'SP_DEVINFO_DATA' : illegal use of this type as an expressionrn e:\win2k programfiles\vc98\include\setupapi.h(515) : see declaration of 'SP_DEVINFO_DATA'rne:\development\device control\netcardctrl.c(105) : error C2146: syntax error : missing ';' before identifier 'DeviceInfoData'rne:\development\device control\netcardctrl.c(105) : error C2065: 'DeviceInfoData' : undeclared identifierrne:\development\device control\netcardctrl.c(105) : error C2059: syntax error : ''rne:\development\device control\netcardctrl.c(107) : error C2275: 'HKEY' : illegal use of this type as an expressionrn e:\win2k programfiles\vc98\include\windef.h(234) : see declaration of 'HKEY'rne:\development\device control\netcardctrl.c(107) : error C2146: syntax error : missing ';' before identifier 'hKeyClass'rne:\development\device control\netcardctrl.c(107) : error C2065: 'hKeyClass' : undeclared identifierrne:\development\device control\netcardctrl.c(108) : error C2143: syntax error : missing ';' before 'type'rne:\development\device control\netcardctrl.c(109) : warning C4133: 'function' : incompatible types - from 'int *' to 'struct _SP_DEVINFO_DATA *'rne:\development\device control\netcardctrl.c(111) : error C2224: left of '.ClassGuid' must have struct/union typerne:\development\device control\netcardctrl.c(111) : error C2198: 'IsClassNet' : too few actual parametersrn恳请帮忙,不胜感激!

没有更多推荐了,返回首页