Pelagicore / qface-qtmqtt

Work in Progress: MQTT qface generator for Qt based solutions
MIT License
0 stars 2 forks source link

Problems with README instructions #1

Open evadeflow opened 5 years ago

evadeflow commented 5 years ago

I had some issues with the instructions in the README. I modified them as shown below and managed to get some output, but I'm not sure whether it's correct:

mkdir mqtt && cd mqtt                                                                                                                                                                                                                                          
git clone https://github.com/emqtt/qmqtt.git
cd qmqtt
mkdir build && cd build
$HOME/Qt/5.9.2/gcc_64/bin/qmake .. && make && make install
cd ../..   # <<<<<<<<<<<<<<<<<<<< I ADDED THIS LINE
virtualenv -p python3 ./venv
source venv/bin/activate
pip install git+https://github.com/Pelagicore/qface.git#master 
git clone https://github.com/Pelagicore/qface-qtmqtt.git # <<<<<<<<<<<<<<<<<<<< I CHANGED THIS LINE (use HTTPS rather than Git procotol)
cat > counter.qface << HERE 
module counter 1.0

interface Counter {

    int count;   // <<<<<<<<<<<<<<<<<<<< I CHANGED THIS LINE (added semi-colon)
    void increment();
    void decrement();
}
HERE
qface --rules qface-qtmqtt/qface-rules.yml --target out counter.qface # <<<<<<<<<<<<<<<<<<<< I CHANGED THIS LINE (path to rules file)

The output of the last command showed some errors:

face uses language profile: EProfile.FULL
process: server
create: out/servers/server_counter/server_counter.pro
create: out/servers/server_counter/main.cpp
create: out/servers/server_counter/counterservice.cpp
create: out/servers/server_counter/counterservice.h
process: apps
process: lib
create: out/libs/lib_counter/lib_counter.pro
create: out/libs/lib_counter/lib.qrc
create: out/libs/lib_counter/mqtt.conf
qface-qtmqtt/templates/libs/lib/mqttclient.h:7: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/mqttclient.h:7: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/mqttclient.cpp:4: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/mqttclient.cpp:4: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/variantmodel.h:10: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/variantmodel.h:10: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/variantmodel.cpp:8: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/variantmodel.cpp:8: error: no filter named 'qt.open_ns'
create: out/libs/lib_counter/use_lib_counter.pri
qface-qtmqtt/templates/libs/lib/shared.h:5: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/shared.h:5: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/shared.cpp:3: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/shared.cpp:3: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/client.h:11: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/client.h:11: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/client.cpp:10: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/client.cpp:10: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/abstractservice.h:12: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/abstractservice.h:12: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/abstractservice.cpp:11: error: no filter named 'qt.open_ns'
qface-qtmqtt/templates/libs/lib/abstractservice.cpp:11: error: no filter named 'qt.open_ns'
process: plugins
create: out/plugins/plugin_counter/plugin_counter.pro
create: out/plugins/plugin_counter/qmldir
create: out/plugins/plugin_counter/plugin.cpp
create: out/plugins/plugin_counter/plugin.h
process: general
create: out/plugins/plugin_counter/out.pro
create: out/plugins/plugin_counter/.qmake.conf
create: out/plugins/plugin_counter/apps/apps.pro
create: out/plugins/plugin_counter/plugins/plugins.pro
create: out/plugins/plugin_counter/servers/servers.pro
create: out/plugins/plugin_counter/libs/libs.pro

They were colored RED, but it's not clear whether these were 'real' errors, or more like warnings. As a result, I'm not sure whether my changes (indicated above with >>>>>>>>>>) were correct. The last command did generate some artifacts:

$ tree out 
out
├── libs
│   └── lib_counter
│       ├── lib_counter.pro
│       ├── lib.qrc
│       ├── mqtt.conf
│       └── use_lib_counter.pri
├── plugins
│   └── plugin_counter
│       ├── apps
│       │   └── apps.pro
│       ├── libs
│       │   └── libs.pro
│       ├── out.pro
│       ├── plugin_counter.pro
│       ├── plugin.cpp
│       ├── plugin.h
│       ├── plugins
│       │   └── plugins.pro
│       ├── qmldir
│       └── servers
│           └── servers.pro
└── servers
    └── server_counter
        ├── counterservice.cpp
        ├── counterservice.h
        ├── main.cpp
        └── server_counter.pro

I'm just not sure whether I should trust them, given the error messages and the changes I had to make to the instructions to get to this point.

jryannel commented 5 years ago

The errors are errors :-)

I expect you installed qface from the master branch. Which is wrongly described in the README. I updated the README to use qface from the develop branch. Ideally I should make a release first, but some features are really fresh currently.