繁体   English   中英

创建自定义小部件Gtk2 / C?

[英]Creating Custom Widget Gtk2/C?

我正在看一本书(Gtk +的基础),当我编译这些文件时:

http://pastebin.com/LagSdYwF

http://pastebin.com/0wNV6Feb

http://pastebin.com/iK0cfMY6

终端输出以下内容(gcc ipaddresstest.c $(pkg-config --cflags --libs gtk + -2.0)):

ipaddresstest.c :(。文字+ 0xC9):对“ my_ip_address_new”的未定义引用

ipaddresstest.c :(。文字+ 0xD2):对“ my_ip_address_get_type”的未定义引用

ipaddresstest.c :(。文字+ 0xF6):对“ my_ip_address_set_address”的未定义引用

/tmp/cclTaXSL.o:在“ ip_address_changed”函数中:

ipaddresstest.c :(。文字+ 0x183):对“ my_ip_address_get_address”的未定义引用

collect2:错误:ld返回1退出状态

我对此一无所获。 错误在哪里?

PS:您能告诉我有关gtk3这个论点的指南吗?

您引用的符号无法解析。 可能是因为在调用gcc时没有提及具有功能定义的myipaddress.c吗?

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM