PDA

View Full Version : adding external library



anh5kor
31st October 2014, 08:01
Hello,

I am trying to add external lib in my Qt Project in two way

1.By right click on code editor ->add library->External Library->path and name
2.By giving the full path LIBS += -L"D:\EMU\EMU6\InterFace_D2XXFTDI\InterFace_D2XXFTDI\ libs" -lftd2xx

In my case 2nd one is working but in 1st case I am getting a error " error: cannot find -lftd2xx"

please let me know why I am getting the error.
Actually I want to add Relative path not the absolute path.

StrikeByte
10th November 2014, 16:32
you can use $$PWD to point to the project directory and go up from there
examle: -L$$PWD/../../../EMU\EMU6\InterFace_D2XXFTDI\InterFace_D2XXFTD I\libs (EMU is 3 dirs up from the project directory)