2

I'm trying to deploy an application,using the latest versions of Qt, OpenCV and CQTDeployer From QuasarApp, but when I run it I get this error:

    Project ERROR: Failed to run:  config/controlScript.js  -ts config/ru.ts

I'm using the administrator account, already checked my permissions just in case, also checked the ru.ts file, downloaded the files needed (it had the option directly in qt), but still wasn't able to fix this error.

Followed the READ ME and when I get to the step:

* qmake -r
* Here you must definitely call the qmake that was loaded from thstrong text1st item.
* Example: ~/Qt/5.14.0/gcc_64/bin/qmake -r

It shows me the "QMake has two modes..." message.

Syscall
  • 19,327
  • 10
  • 37
  • 52
Ricardo landry
  • 63
  • 1
  • 1
  • 8
  • I see that you are trying to build cqtdeployer yourself. Have you tried using the pre-built assembly? From [here](https://github.com/QuasarApp/CQtDeployer/releases/tag/1.4.5) of [snap store](https://snapcraft.io/cqtdeployer) – Andrey Yankovich Jul 17 '20 at 06:41
  • It worked, I didn't use it before because a month ago it didn't let me, do you know how could I make the executable for Windows using it? – Ricardo landry Jul 17 '20 at 14:45
  • if you want create windows executable file from your application only with cqtdeployer then this is impossible because CQtDeployer it is utility for deploying for already exists application files. First one, you need to build your application for windows platform uses cross platform competitors. For example I am use the [mingw](http://mingw-w64.org/doku.php/download/linux) for build my applications for windows. – Andrey Yankovich Jul 18 '20 at 10:24
  • Thank you very much, I'll be better telling the university to install linux too, hahaha. How can I mark my question as solved with the comment? – Ricardo landry Jul 18 '20 at 22:38

1 Answers1

1

if you want create windows executable file from your application only with cqtdeployer then this is impossible because CQtDeployer it is utility for deploying for already exists application files.

First one, you need to build your application for windows platform uses cross platform competitors.

For example I am use the mingw for build my applications for windows.

Crossplatform build

Steps for crossplatform builds

  1. Build Qt for Windows with crossplatform compilar mingw see this post
  2. Build OpenCV for Windows with crossplatform compilar mingw. however, I have not found any article for cross-platform OpenCV build, it may not be possible.
  3. Build your Application with OpenCV and Qt from step 1 and 2
  4. Deploy you application
cqtdeployer -bin myApp.exe -libDir /dir/with/OpenCV/Library -qmake /path/to/buildet/qmake.exe 

WSL2

I can also suggest the life hack for your situation.

  1. Build an application for Linux
  2. Deploy the application for Linux (without the deploySystem option, if you add it, most likely the application will not work)
  3. Install on Windows WSL2
  4. Configure Run Gui applications in WSL2
  5. Install your Linux application on Windows and run it through the WSL2 console
Andrey Yankovich
  • 868
  • 9
  • 13