首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >gSoap QT未定义引用

gSoap QT未定义引用
EN

Stack Overflow用户
提问于 2015-03-24 15:44:29
回答 1查看 235关注 0票数 0

我试图使用gSOAP创建一个c++/QT服务器/客户端

这是我的Test.h文件

代码语言:javascript
复制
//gsoap ns service name:    ColisageMutexService
//gsoap ns service style:   rpc
//gsoap ns service encoding:    literal
//gsoap ns service location:    http://localhost:1444
//gsoap ns schema namespace: urn:ColisageMutex
class FamilleProduit
{
private:
    int Id;
    std::string Libelle;
public:
    FamilleProduit();
    ~FamilleProduit();
    int getId();
    void setId(int value);
    std::string getLibelle();
    void setLibelle(std::string value);
};

//gsoap ns service method-action: ajouterByType ""

int ns__ajouterByType ( FamilleProduit familleproduit, bool * result);

//gsoap ns service method-action: ajouterByLibelle ""

int ns__ajouterByLibelle ( std::string libelle, bool * result);

我运行oapcpp2.exe -I -pTest Test.h,并将生成的代码集成到我的项目中,但是编译器一直给我错误的问题。

代码语言:javascript
复制
error: undefined reference to `ns__ajouterByType(soap*, FamilleProduit, bool*)

代码语言:javascript
复制
error: undefined reference to `ns__ajouterByLibelle(soap*, std::string, bool*)

即使是我在主程序中添加了这个两个函数的实现。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-03-26 13:48:37

问题是在实施我忘记了的方法

代码语言:javascript
复制
struct soap* soap

在方法定义中

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/29237012

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档