Hi there. While compiling a file I keep on receiving two warnings and one error -
D:\Spatial sources\projects\QUnwrap/qunwrap.cpp:14: undefined reference to `start_unwrap(int, char**)'
D:\Spatial sources\projects\QUnwrap/qunwrap.cpp:14: undefined reference to `start_unwrap(int, char**)'
error: collect2: ld returned 1 exit status
#include "qunwrap.h"
#include "ui_qunwrap.h"
#include "snaphu_src/snaphu.h"
QUnwrap
::QUnwrap(QWidget *parent
) : ui(new Ui::QUnwrap)
{
ui->setupUi(this);
int first_arg;
char** sec_arg;
start_unwrap(first_arg, sec_arg);
}
QUnwrap::~QUnwrap()
{
delete ui;
}
void QUnwrap
::changeEvent(QEvent *e
) {
switch (e->type()) {
ui->retranslateUi(this);
break;
default:
break;
}
}
#include "qunwrap.h"
#include "ui_qunwrap.h"
#include "snaphu_src/snaphu.h"
QUnwrap::QUnwrap(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::QUnwrap)
{
ui->setupUi(this);
int first_arg;
char** sec_arg;
start_unwrap(first_arg, sec_arg);
}
QUnwrap::~QUnwrap()
{
delete ui;
}
void QUnwrap::changeEvent(QEvent *e)
{
QMainWindow::changeEvent(e);
switch (e->type()) {
case QEvent::LanguageChange:
ui->retranslateUi(this);
break;
default:
break;
}
}
To copy to clipboard, switch view to plain text mode
File "snaphu.h"
.....
void start_unwrap(int argc, char **argv);// main procedure
.....
.....
void start_unwrap(int argc, char **argv);// main procedure
.....
To copy to clipboard, switch view to plain text mode
File "snaphu.c"
void start_unwrap(int argc, char **argv){
//some code here
}
void start_unwrap(int argc, char **argv){
//some code here
}
To copy to clipboard, switch view to plain text mode
If I comment the line
start_unwrap(first_arg, sec_arg);
start_unwrap(first_arg, sec_arg);
To copy to clipboard, switch view to plain text mode
, Qt compiles it.
What's wrong with it? I'm using QT Creator. Thank you for any help in advance.
Bookmarks