
Originally Posted by
ksniffer
You need to install the FreeBSD ports. You cannot use Linux binary application directly, you could use the linux binary compatibility generally, but you have Qt4 under FreeBSD natively, so install the ports. See into the handbook how to install a port .
thx for reply sniffer,
now i have installed qt4.4.3 from freebsd ports collection.
all packet qt i have installed.
i try to make a simple program
#include <QApplication>
#include <QWidget>
int main(int argc, char *argv[])
{
window.resize(250, 150);
window.setWindowTitle("Simple example");
window.show();
return app.exec();
}
#include <QApplication>
#include <QWidget>
int main(int argc, char *argv[])
{
QApplication app(argc, argv) ;
QWidget window;
window.resize(250, 150);
window.setWindowTitle("Simple example");
window.show();
return app.exec();
}
To copy to clipboard, switch view to plain text mode
i saved at /web/qt/qt1/text.cpp
now i compile it from terminal and this is my command :
root# pwd
/tms/QT/qt1
root# ls
test.cpp
root# qmake -project
root# qmake
QMAKESPEC has not been set, so configuration cannot be deduced.
Error processing project file: /web/QT/qt1/qt1.pro
root# pwd
/tms/QT/qt1
root# ls
test.cpp
root# qmake -project
root# qmake
QMAKESPEC has not been set, so configuration cannot be deduced.
Error processing project file: /web/QT/qt1/qt1.pro
To copy to clipboard, switch view to plain text mode
i have edit file ./profile
.lf 1 /root/.profile
# $FreeBSD: src/etc/root/dot.profile,v 1.21.8.1 2009/04/15 03:14:26 kensmith Exp $
#
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:~/bin
export PATH
HOME=/root
export HOME
TERM=${TERM:-cons25}
export TERM
PAGER=more
export PAGER
QMAKESPEC=/usr/local/share/qt4/mkspecs/freebsd-g++
export QMAKESPEC
.lf 1 /root/.profile
# $FreeBSD: src/etc/root/dot.profile,v 1.21.8.1 2009/04/15 03:14:26 kensmith Exp $
#
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:~/bin
export PATH
HOME=/root
export HOME
TERM=${TERM:-cons25}
export TERM
PAGER=more
export PAGER
QMAKESPEC=/usr/local/share/qt4/mkspecs/freebsd-g++
export QMAKESPEC
To copy to clipboard, switch view to plain text mode
when i type qmake, there is error :
QMAKESPEC has not been set, so configuration cannot be deduced.
Error processing project file: /web/QT/qt1/qt1.pro
how to fix it? is there another setting ???
thx u for reply
Bookmarks