FreeBSD > Compiling application with QT

last updated in Categories News

Qt is a complete C++ application framework (toolkit), including a class library and tools for cross-platform. While compile qt application under FreeBSD you get error:


/bin/uic about.ui -o about.h
/bin/uic:No such file or directory
*** Error code 1

Stop in /home/projects/nqe.

To get rid of this problem:
1) To compile application under QT define QTDIR variable (assuming you are using bash shell)
$ export QTDIR=/usr/X11R6

You can add this line to your startup shell script i.e. ~/.bash_profile

2) Compile your qt application:
$ cd /path/to/appdir
$ qmake -project
$ qmake
$ make

3) Execute your code.

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin, DevOps engineer, and a trainer for the Linux operating system/Unix shell scripting. Get the latest tutorials on SysAdmin, Linux/Unix and open source topics via RSS/XML feed or weekly email newsletter.


Leave a Comment