QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

楼主: alpher

发布连连看2.3测试版

[复制链接]
 楼主| 发表于 2006-8-7 00:36:30 | 显示全部楼层
楼上两位:

good job
add oil
做的差不多了给我看看,如果可以,我把sourceforge的管理权限给你
以后就由你来维护这个项目
不过我建议SDL是可以做,但是最好做成可选功能
即使没有SDL,会损失一些功能,但是游戏还是要能玩
加油!!!
回复

使用道具 举报

发表于 2006-8-7 22:53:19 | 显示全部楼层

背景音乐部分做好了,稍后会放出

[code:1]#include "stdlib.h"
#include "SDL/SDL.h"
// *** IF USING XCODE ON MACOS X, YOU MAY NEED TO CHANGE THE FOLLOWING LINE TO:  #include "SDL_mixer/SDL_mixer.h"
#include "SDL/SDL_mixer.h"
#include <SDL_PlayMusic.h>

int musicPlaying = 0;
int musicInit=0;
char *music_file[MUSIC_NUM]={"01.ogg","02.ogg","03.ogg"};
Mix_Music *music[3];

int music_init()
{
                        //Pointer to our music, in memory
        int i;
        int audio_rate = 22050;                        //Frequency of audio playback
        Uint16 audio_format = AUDIO_S16SYS;         //Format of the audio we're playing
        int audio_channels = 2;                        //2 channels = stereo
        int audio_buffers = 4096;                //Size of the audio buffers in memory
       
        //Initialize SDL audio
        if (SDL_Init(SDL_INIT_AUDIO) != 0)
        {
                printf("Unable to initialize SDL: %s\n", SDL_GetError());
                return 1;
        }
       
        //Initialize SDL_mixer with our chosen audio settings
        if(Mix_OpenAudio(audio_rate, audio_format, audio_channels, audio_buffers) != 0)
        {
                printf("Unable to initialize audio: %s\n", Mix_GetError());
                return 1;
        }
       
        //Load our OGG file from disk
        for(i=0;i<MUSIC_NUM;i++)
        {
                music[i] = Mix_LoadMUS(music_file[i]);
                if(music[i] == NULL)
                printf("Unable to load OGG file: %s\n", Mix_GetError());
        }
        musicInit=1;
        return 0;
}
void music_close()
{
        int i;       
//Release the memory allocated to our music
        Mix_HaltMusic();
        for(i=0;i<MUSIC_NUM;i++)
        Mix_FreeMusic(music[i]);
       
        //Need to make sure that SDL_mixer and SDL have a chance to clean up
        Mix_CloseAudio();
        SDL_Quit();       
        musicInit=0;
        //Return success!
}

int music_playing()
//Is the music playing, or not?
{
        return musicPlaying;
}
int music_play(int i)
{
        //int i;
        /*if(i<0||i>=MUSIC_NUM)
        {       
                printf("error for num%d\n",i);
                return -1;
        }*/
        if(musicInit==0)
        {
                if(music_init()!=0)
                        return -1;
        }
        for(i=0;i<MUSIC_NUM;i++)
        {
                //Play that funky music!
                if(Mix_PlayMusic(music[i], 0) == -1)
                {
                        printf("Unable to play OGG file: %s\n", Mix_GetError());
                        return 1;
                }
                //The music is playing!
                musicPlaying = 1;
                //Make sure that the musicFinished() function is called when the music stops playing
                Mix_HookMusicFinished(musicFinished);
                //Wait for the music to stop
                while(musicPlaying)
                {
                        //Do nothing for a bit
                        SDL_Delay(100);
                }
                if(i==MUSIC_NUM-1) i=0;
        }
        return 0;
}

void musicFinished()
{
        //Music is done!
        musicPlaying = 0;
}
/*
int main()
{
        music_init();
        music_play(0);
        music_close();
        return 0;
}*/
[/code:1]
这个是SDL_PlayMusic.c
直接参考了SDL自己的示范代码和楼上那位兄弟的代码。
Play_sound这一部分没有动,想看看大家对SDL的看法。
回复

使用道具 举报

发表于 2006-9-5 23:14:44 | 显示全部楼层
报错,找不到
SDL_PlayMusic.h

在哪个包里啊?
回复

使用道具 举报

发表于 2006-9-6 22:36:19 | 显示全部楼层
已经发布到fans拉,请到软件下载去找。
回复

使用道具 举报

发表于 2006-9-8 08:44:56 | 显示全部楼层
我是在软件栏下载的, 错误如下
[code:1]
yang@druggo ~/d/llk_linux-2.3 $ make
make  all-recursive
make[1]: Entering directory `/home/yang/Desktop/llk_linux-2.3'
Making all in po
make[2]: Entering directory `/home/yang/Desktop/llk_linux-2.3/po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/yang/Desktop/llk_linux-2.3/po'
Making all in include
make[2]: Entering directory `/home/yang/Desktop/llk_linux-2.3/include'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/yang/Desktop/llk_linux-2.3/include'
Making all in src
make[2]: Entering directory `/home/yang/Desktop/llk_linux-2.3/src'
if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -I../ -I../include   `pkg-config --cflags --libs gtk+-2.0` `sdl-config --cflags --libs` -Wall -g -g -O2 -MT main.o -MD -MP -MF ".deps/main.Tpo" -c -o main.o main.c; \
        then mv -f ".deps/main.Tpo" ".deps/main.Po"; else rm -f ".deps/main.Tpo"; exit 1; fi
main.c:26:27: error: SDL_PlayMusic.h: No such file or directory
main.c: In function 'ui_game_begin':
main.c:624: warning: implicit declaration of function 'ui_if_music'
main.c: In function 'ui_game_over':
main.c:816: warning: implicit declaration of function 'music_close'
main.c: In function 'ui_use_m_s_bg':
main.c:1580: warning: implicit declaration of function 'ui_if_customise'
main.c: In function 'game_play_music':
main.c:2224: error: 'music_play' undeclared (first use in this function)
main.c:2224: error: (Each undeclared identifier is reported only once
main.c:2224: error: for each function it appears in.)
main.c:2218: warning: unused variable 'i'
make[2]: *** [main.o] Error 1
make[2]: Leaving directory `/home/yang/Desktop/llk_linux-2.3/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/yang/Desktop/llk_linux-2.3'
make: *** [all] Error 2
yang@druggo ~/d/llk_linux-2.3 $[/code:1]
回复

使用道具 举报

发表于 2006-9-9 19:38:48 | 显示全部楼层
我是新手,在红帽上能用吗
回复

使用道具 举报

发表于 2006-9-10 15:33:52 | 显示全部楼层
我用vmware装的Red hat 9的系统,结果编译出的错误如下:
[root@localhost llk_linux-2.3]# make
make  all-recursive
make[1]: Entering directory `/home/game/llk_linux-2.3'
Making all in po
make[2]: Entering directory `/home/game/llk_linux-2.3/po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/game/llk_linux-2.3/po'
Making all in include
make[2]: Entering directory `/home/game/llk_linux-2.3/include'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/game/llk_linux-2.3/include'
Making all in src
make[2]: Entering directory `/home/game/llk_linux-2.3/src'
if gcc -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/X11R6/include -I/usr/include/freetype2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -I../ -I../include   `pkg-config --cflags --libs gtk+-2.0` -Wall -g -g -O2 -MT main.o -MD -MP -MF ".deps/main.Tpo" -c -o main.o main.c; \
then mv -f ".deps/main.Tpo" ".deps/main.Po"; else rm -f ".deps/main.Tpo"; exit 1; fi
In file included from main.c:25:
../include/main.h:29:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/main.h:43,
                 from main.c:25:
../include/llk_algorithm.h:30:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/main.h:44,
                 from main.c:25:
../include/llk_about.h:30:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/llk_about.h:31,
                 from ../include/main.h:44,
                 from main.c:25:
../include/pak.h:37:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/main.h:46,
                 from main.c:25:
../include/create_pak.h:28:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/main.h:47,
                 from main.c:25:
../include/llk_inifile.h:30:24: glib/gi18n.h: 没有那个文件或目录
In file included from ../include/main.h:48,
                 from main.c:25:
../include/tray.h:48: syntax error before "GtkUIManager"
../include/tray.h:48: warning: no semicolon at end of struct or union
../include/tray.h:49: warning: type defaults to `int' in declaration of `actions'
../include/tray.h:49: warning: data definition has no type or storage class
../include/tray.h:51: syntax error before '}' token
main.c: In function `get_main_menu':
main.c:41: warning: implicit declaration of function `_'
main.c:41: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:45: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:49: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:55: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:59: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:63: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:66: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:69: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:72: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:79: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:82: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:85: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:88: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:91: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:94: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:101: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:110: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:116: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:120: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:124: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:130: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:137: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:140: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:146: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:149: warning: passing arg 1 of `gtk_check_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:152: warning: passing arg 1 of `gtk_check_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:155: warning: passing arg 1 of `gtk_check_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:160: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:164: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:170: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:174: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:178: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:183: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:186: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c:189: warning: passing arg 1 of `gtk_menu_item_new_with_mnemonic' makes pointer from integer without a cast
main.c: In function `ui_hide_window':
main.c:210: dereferencing pointer to incomplete type
main.c:215: dereferencing pointer to incomplete type
main.c:216: dereferencing pointer to incomplete type
main.c:220: dereferencing pointer to incomplete type
main.c:221: dereferencing pointer to incomplete type
main.c: In function `ui_drawingarea_clicked':
main.c:436: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:473: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:494: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:516: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:539: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_game_begin':
main.c:637: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:640: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:678: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:691: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_game_next_level':
main.c:809: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:820: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:827: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_game_shuffle':
main.c:864: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:882: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_game_over':
main.c:905: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:908: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:911: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:917: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:924: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:939: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:953: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_refresh_top':
main.c:1050: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1053: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1056: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1061: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1067: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1070: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1073: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1076: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1079: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1082: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1085: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1088: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1091: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1094: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1097: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1108: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1111: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1118: warning: passing arg 2 of `gtk_label_set_text' makes pointer from integer without a cast
main.c:1119: warning: passing arg 2 of `gtk_label_set_text' makes pointer from integer without a cast
main.c:1120: warning: passing arg 2 of `gtk_label_set_text' makes pointer from integer without a cast
main.c:1122: warning: passing arg 2 of `gtk_label_set_text' makes pointer from integer without a cast
main.c:1123: warning: passing arg 2 of `gtk_label_set_text' makes pointer from integer without a cast
main.c: In function `ui_game_hint':
main.c:1151: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1186: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_load_ini_pak':
main.c:1487: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1499: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1521: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1569: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1582: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1589: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1595: warning: passing arg 1 of `g_strdup_printf' makes pointer from integer without a cast
main.c:1602: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1614: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c:1630: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1637: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1653: warning: passing arg 1 of `g_strdup' makes pointer from integer without a cast
main.c: In function `radio_item_on_clicked':
main.c:1700: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1709: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1716: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1729: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1754: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1761: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:1777: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_save_game_data':
main.c:1825: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_read_game_data':
main.c:1850: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c: In function `ui_input_string':
main.c:1863: warning: passing arg 2 of `gtk_window_set_title' makes pointer from integer without a cast
main.c:1867: warning: passing arg 1 of `gtk_label_new' makes pointer from integer without a cast
main.c:1877: warning: passing arg 1 of `gtk_label_new' makes pointer from integer without a cast
main.c:1886: warning: passing arg 2 of `gtk_dialog_add_button' makes pointer from integer without a cast
main.c:1888: warning: passing arg 2 of `gtk_dialog_add_button' makes pointer from integer without a cast
main.c: In function `ui_record_score':
main.c:1953: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:2020: warning: passing arg 2 of `sprintf' makes pointer from integer without a cast
main.c:2022: warning: passing arg 2 of `sprintf' makes pointer from integer without a cast
main.c:2024: warning: passing arg 2 of `sprintf' makes pointer from integer without a cast
main.c:2026: warning: passing arg 2 of `sprintf' makes pointer from integer without a cast
main.c:2048: warning: passing arg 1 of `g_print' makes pointer from integer without a cast
main.c:2064: warning: passing arg 2 of `gtk_window_set_title' makes pointer from integer without a cast
main.c:2070: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2073: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2076: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2079: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2082: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2085: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2088: warning: passing arg 3 of `gtk_tree_view_insert_column_with_attributes' makes pointer from integer without a cast
main.c:2129: warning: passing arg 1 of `gtk_button_new_with_label' makes pointer from integer without a cast
main.c: At top level:
main.c:2145: syntax error before '*' token
main.c: In function `tray_popup_activate_action':
main.c:2147: warning: implicit declaration of function `gtk_action_get_name'
main.c:2147: `action' undeclared (first use in this function)
main.c:2147: (Each undeclared identifier is reported only once
main.c:2147: for each function it appears in.)
main.c:2147: warning: format argument is not a pointer (arg 4)
main.c: In function `main':
main.c:2163: syntax error before "tray_popup_entries"
main.c:2157: warning: unused variable `window'
main.c:2158: warning: unused variable `main_vbox'
main.c:2158: warning: unused variable `vbox'
main.c:2158: warning: unused variable `hbox'
main.c:2159: warning: unused variable `menubar'
main.c:2160: warning: unused variable `message'
main.c:2161: warning: unused variable `tray'
main.c:2162: warning: unused variable `tray_error'
main.c: At top level:
main.c:2194: syntax error before string constant
main.c:2194: warning: type defaults to `int' in declaration of `bindtextdomain'
main.c:2194: warning: data definition has no type or storage class
main.c:2195: syntax error before string constant
main.c:2195: warning: type defaults to `int' in declaration of `bind_textdomain_codeset'
main.c:2195: warning: data definition has no type or storage class
main.c:2196: syntax error before string constant
main.c:2196: warning: type defaults to `int' in declaration of `textdomain'
main.c:2196: warning: data definition has no type or storage class
main.c:2198: syntax error before '&' token
main.c:2198: warning: type defaults to `int' in declaration of `gtk_init'
main.c:2198: conflicting types for `gtk_init'
/usr/include/gtk-2.0/gtk/gtkmain.h:93: previous declaration of `gtk_init'
main.c:2198: warning: data definition has no type or storage class
main.c:2199: warning: type defaults to `int' in declaration of `window'
main.c:2199: warning: initialization makes integer from pointer without a cast
main.c:2199: initializer element is not constant
main.c:2199: warning: data definition has no type or storage class
main.c:2201: syntax error before '(' token
main.c:2203: warning: type defaults to `int' in declaration of `message'
main.c:2203: warning: format argument is not a pointer (arg 2)
main.c:2203: warning: format argument is not a pointer (arg 4)
main.c:2203: warning: initialization makes integer from pointer without a cast
main.c:2203: initializer element is not constant
main.c:2203: warning: data definition has no type or storage class
main.c:2204: syntax error before '(' token
main.c:2205: warning: type defaults to `int' in declaration of `g_free'
main.c:2205: warning: parameter names (without types) in function declaration
main.c:2205: conflicting types for `g_free'
/usr/include/glib-2.0/glib/gmem.h:52: previous declaration of `g_free'
main.c:2205: warning: data definition has no type or storage class
main.c:2208: syntax error before '(' token
main.c:2210: syntax error before '(' token
main.c:2212: warning: type defaults to `int' in declaration of `tray'
main.c:2212: sizeof applied to an incomplete type
main.c:2212: warning: initialization makes integer from pointer without a cast
main.c:2212: initializer element is not constant
main.c:2212: warning: data definition has no type or storage class
main.c:2213: syntax error before '->' token
main.c:2215: warning: type defaults to `int' in declaration of `llk_create_tray'
main.c:2215: warning: parameter names (without types) in function declaration
main.c:2215: conflicting types for `llk_create_tray'
../include/tray.h:56: previous declaration of `llk_create_tray'
main.c:2215: warning: data definition has no type or storage class
main.c:2217: syntax error before '->' token
main.c:2218: syntax error before '->' token
main.c:2218: warning: type defaults to `int' in declaration of `gtk_action_group_set_translation_domain'
main.c:2218: warning: data definition has no type or storage class
main.c:2219: syntax error before '->' token
main.c:2222: syntax error before '->' token
main.c:2222: warning: type defaults to `int' in declaration of `gtk_ui_manager_insert_action_group'
main.c:2222: warning: data definition has no type or storage class
main.c:2223: syntax error before '(' token
main.c:2228: warning: type defaults to `int' in declaration of `g_error_free'
main.c:2228: warning: parameter names (without types) in function declaration
main.c:2228: conflicting types for `g_error_free'
/usr/include/glib-2.0/glib/gerror.h:46: previous declaration of `g_error_free'
main.c:2228: warning: data definition has no type or storage class
main.c:2229: syntax error before '}' token
main.c:2232: warning: type defaults to `int' in declaration of `main_vbox'
main.c:2232: warning: initialization makes integer from pointer without a cast
main.c:2232: initializer element is not constant
main.c:2232: warning: data definition has no type or storage class
main.c:2233: syntax error before '(' token
main.c:2234: syntax error before '(' token
main.c:2235: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2235: warning: parameter names (without types) in function declaration
main.c:2235: conflicting types for `gtk_widget_show'
/usr/include/gtk-2.0/gtk/gtkwidget.h:447: previous declaration of `gtk_widget_show'
main.c:2235: warning: data definition has no type or storage class
main.c:2238: warning: type defaults to `int' in declaration of `vbox'
main.c:2238: warning: initialization makes integer from pointer without a cast
main.c:2238: initializer element is not constant
main.c:2238: warning: data definition has no type or storage class
main.c:2239: syntax error before '(' token
main.c:2240: syntax error before '(' token
main.c:2241: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2241: warning: parameter names (without types) in function declaration
main.c:2241: warning: data definition has no type or storage class
main.c:2242: syntax error before '&' token
main.c:2242: warning: type defaults to `int' in declaration of `get_main_menu'
main.c:2242: conflicting types for `get_main_menu'
main.c:32: previous declaration of `get_main_menu'
main.c:2242: warning: data definition has no type or storage class
main.c:2245: syntax error before '(' token
main.c:2246: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2246: warning: parameter names (without types) in function declaration
main.c:2246: warning: data definition has no type or storage class
main.c:2252: syntax error before '(' token
main.c:2255: warning: type defaults to `int' in declaration of `hbox'
main.c:2255: warning: initialization makes integer from pointer without a cast
main.c:2255: initializer element is not constant
main.c:2255: warning: data definition has no type or storage class
main.c:2256: syntax error before '(' token
main.c:2257: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2257: warning: parameter names (without types) in function declaration
main.c:2257: warning: data definition has no type or storage class
main.c:2258: syntax error before '.' token
main.c:2259: syntax error before '.' token
main.c:2259: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2259: conflicting types for `gtk_widget_set_size_request'
/usr/include/gtk-2.0/gtk/gtkwidget.h:559: previous declaration of `gtk_widget_set_size_request'
main.c:2259: warning: data definition has no type or storage class
main.c:2260: syntax error before '(' token
main.c:2261: syntax error before '(' token
main.c:2262: syntax error before '.' token
main.c:2262: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2262: warning: data definition has no type or storage class
main.c:2263: syntax error before '.' token
main.c:2264: syntax error before '.' token
main.c:2264: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2264: warning: data definition has no type or storage class
main.c:2265: syntax error before '(' token
main.c:2266: syntax error before '(' token
main.c:2267: syntax error before '.' token
main.c:2267: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2267: warning: data definition has no type or storage class
main.c:2268: syntax error before '.' token
main.c:2269: syntax error before '.' token
main.c:2269: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2269: warning: data definition has no type or storage class
main.c:2270: syntax error before '(' token
main.c:2271: syntax error before '(' token
main.c:2272: syntax error before '.' token
main.c:2272: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2272: warning: data definition has no type or storage class
main.c:2273: syntax error before '.' token
main.c:2274: syntax error before '.' token
main.c:2274: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2274: warning: data definition has no type or storage class
main.c:2275: syntax error before '(' token
main.c:2276: syntax error before '(' token
main.c:2277: syntax error before '.' token
main.c:2277: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2277: warning: data definition has no type or storage class
main.c:2278: syntax error before '.' token
main.c:2279: syntax error before '.' token
main.c:2279: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2279: warning: data definition has no type or storage class
main.c:2280: syntax error before '(' token
main.c:2281: syntax error before '(' token
main.c:2282: syntax error before '.' token
main.c:2282: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2282: warning: data definition has no type or storage class
main.c:2283: syntax error before '.' token
main.c:2284: syntax error before '.' token
main.c:2284: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2284: warning: data definition has no type or storage class
main.c:2285: syntax error before '(' token
main.c:2286: syntax error before '.' token
main.c:2286: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2286: warning: data definition has no type or storage class
main.c:2287: syntax error before '(' token
main.c:2289: syntax error before '.' token
main.c:2289: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2289: warning: data definition has no type or storage class
main.c:2290: syntax error before '(' token
main.c:2291: syntax error before '(' token
main.c:2292: syntax error before '.' token
main.c:2292: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2292: warning: data definition has no type or storage class
main.c:2295: warning: type defaults to `int' in declaration of `vbox'
main.c:2295: redefinition of `vbox'
main.c:2238: `vbox' previously defined here
main.c:2295: warning: initialization makes integer from pointer without a cast
main.c:2295: initializer element is not constant
main.c:2295: warning: data definition has no type or storage class
main.c:2296: syntax error before '(' token
main.c:2297: syntax error before '(' token
main.c:2298: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2298: warning: parameter names (without types) in function declaration
main.c:2298: warning: data definition has no type or storage class
main.c:2299: warning: type defaults to `int' in declaration of `ui_drawingarea'
main.c:2299: conflicting types for `ui_drawingarea'
../include/main.h:71: previous declaration of `ui_drawingarea'
main.c:2299: warning: data definition has no type or storage class
main.c:2300: syntax error before numeric constant
main.c:2300: warning: type defaults to `int' in declaration of `gtk_widget_set_size_request'
main.c:2300: warning: data definition has no type or storage class
main.c:2301: syntax error before '(' token
main.c:2303: syntax error before '(' token
main.c:2305: syntax error before '(' token
main.c:2307: syntax error before '(' token
main.c:2310: syntax error before '|' token
main.c:2312: warning: type defaults to `int' in declaration of `gtk_widget_set_events'
main.c:2312: conflicting types for `gtk_widget_set_events'
/usr/include/gtk-2.0/gtk/gtkwidget.h:573: previous declaration of `gtk_widget_set_events'
main.c:2312: warning: data definition has no type or storage class
main.c:2314: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2314: warning: parameter names (without types) in function declaration
main.c:2314: warning: data definition has no type or storage class
main.c:2315: warning: type defaults to `int' in declaration of `gtk_widget_show'
main.c:2315: warning: parameter names (without types) in function declaration
main.c:2315: warning: data definition has no type or storage class
main.c:2317: warning: type defaults to `int' in declaration of `ui_rand'
main.c:2317: conflicting types for `ui_rand'
../include/main.h:131: previous declaration of `ui_rand'
main.c:2317: warning: data definition has no type or storage class
main.c:2319: syntax error before "if"
main.c:2322: warning: type defaults to `int' in declaration of `dialog'
main.c:2323: warning: passing arg 5 of `gtk_message_dialog_new' makes pointer from integer without a cast
main.c:2323: warning: initialization makes integer from pointer without a cast
main.c:2323: initializer element is not constant
main.c:2323: warning: data definition has no type or storage class
main.c:2324: syntax error before '(' token
main.c:2325: warning: type defaults to `int' in declaration of `g_free'
main.c:2325: warning: parameter names (without types) in function declaration
main.c:2325: warning: data definition has no type or storage class
main.c:2326: warning: type defaults to `int' in declaration of `gtk_widget_destroy'
main.c:2326: warning: parameter names (without types) in function declaration
main.c:2326: conflicting types for `gtk_widget_destroy'
/usr/include/gtk-2.0/gtk/gtkwidget.h:438: previous declaration of `gtk_widget_destroy'
main.c:2326: warning: data definition has no type or storage class
main.c:2327: syntax error before "return"
main.c:2330: syntax error before '(' token
main.c:2331: warning: type defaults to `int' in declaration of `ui_game_init'
main.c:2331: warning: data definition has no type or storage class
main.c:2332: warning: type defaults to `int' in declaration of `esd_fd'
main.c:2332: initializer element is not constant
main.c:2332: warning: data definition has no type or storage class
main.c:2333: warning: type defaults to `int' in declaration of `gtk_main'
main.c:2333: conflicting types for `gtk_main'
/usr/include/gtk-2.0/gtk/gtkmain.h:133: previous declaration of `gtk_main'
main.c:2333: warning: data definition has no type or storage class
main.c:2334: syntax error before "if"
main.c:1428: warning: `configure_event' defined but not used
main.c:1451: warning: `expose_event' defined but not used
main.c:2146: warning: `tray_popup_activate_action' defined but not used
main.c:2182: warning: `tray_popup_ui_info' defined but not used
make[2]: *** [main.o] Error 1
make[2]: Leaving directory `/home/game/llk_linux-2.3/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/game/llk_linux-2.3'
make: *** [all] Error 2
[root@localhost llk_linux-2.3]# ___
回复

使用道具 举报

发表于 2006-9-14 20:04:18 | 显示全部楼层

出了点差错

请大家重新下载一次,上次的文件出了点差错。有个头文件没有发布。
回复

使用道具 举报

发表于 2006-9-15 11:54:10 | 显示全部楼层
害我好苦啊……
回复

使用道具 举报

发表于 2006-10-25 23:10:19 | 显示全部楼层
编译出错
系统环境是ubuntu 6.06
##########################
gcc: -lgtk-x11-2.0:未使用链接器输入文件,因为链接尚未完成
gcc: -lgdk-x11-2.0:未使用链接器输入文件,因为链接尚未完成
gcc: -latk-1.0:未使用链接器输入文件,因为链接尚未完成
gcc: -lgdk_pixbuf-2.0:未使用链接器输入文件,因为链接尚未完成
gcc: -lm:未使用链接器输入文件,因为链接尚未完成

####################
请问这该何解?
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-4-20 13:38 , Processed in 0.118354 second(s), 13 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表