Not able to run CDatacollection demo in my ubuntu x86 machine - kaa

I installed a sandbox image in my vb successfully and then I
downloaded CDatacollection demo C sdk. But when I run the
application I got the following error, not sure what is the issue.
Kindly let me know, how can I fix this?
sudo ./build.sh build
================================== BUILD_TYPE = (Default) KAA_PLATFORM = posix KAA_MAX_LOG_LEVEL = 3
================================== BOOTSTRAP ENABLED PROFILE ENABLED USER EXTENSION ENABLED CONFIGURATION ENABLED EVENTS ENABLED LOGGING
ENABLED NOTIFICATION ENABLED ENCRYPTION ENABLED KAA WILL BE
INSTALLED TO /usr/local
-- Configuring done CMake Error at targets/posix/CMakeLists.txt:18 (add_library): Cannot find source file:
INTERFACE
Tried these extensions:
.c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp .hxx .in .txx
Regards Rurban

Rurban!
We have investigated your problem. CMake fails to configure because INTERFACE library targets are not supported in CMake 2.x version.
To resolve the issue, try to update CMake to version 3.0.2 or later.
We also have opened the ticket to update the cmake_minimum_required() statement in the Kaa C SDK sample applications. You can see it here -- http://jira.kaaproject.org/browse/APP-527.
Please let me know if the problem has been solved.
Best regards,
Maksim

Related

Error while building ParaView custom app in Windows 10

I have build ParaView superbuild following steps that I found in another question.
Steps to build ParaView superbuild in Windows 10:
Install Visual Studio 2015 community with all C++ related tools
Install cmake
Install git bash
Install Ninja
Install Qt 5.9.9 VS2015 64 bits
then :
Open VS2015 x64 Native Tools Command Prompt and execute: cmake-gui
ENABLE_qt5 and USE_SYSTEM_qt5
ENABLE_python
ENABLE_python2
and add: Qt5_DIR = C:/Qt/5.9.9/msvc2015_64/lib/cmake/Qt5
configure
generate
Result:
Determined source version for paraview: 5.7.0
Enabling cxx11 as requested.
Enabling ftjam as requested.
Enabling nlohmannjson as requested.
Enabling zlib for: hdf5
Enabling szip for: hdf5
Enabling hdf5 for: paraview
Enabling python2 as requested.
Enabling python as requested.
Enabling qt5 as requested.
Enabling paraview as requested.
Building projects: cxx11, ftjam, nlohmannjson, zlib, szip, hdf5, python2, python, qt5, paraview
Configuring done
Generating done
Then:
close cmake-gui
ninja
After a couple hours, it seems to build successfully.
I then download Clone1 from https://gitlab.kitware.com/paraview/paraview/tree/master/Examples/CustomApplications
Open VS2015 x64 Native Tools Command Prompt and execute: cmake-gui
Add:
Qt5_DIR = C:/Qt/5.9.9/msvc2015_64/lib/cmake/Qt5
ParaView_DIR = C:\Users\user\Desktop\paraview\buildvs2015\install\lib\cmake\paraview-5.7
Then:
configure
generate
And I got:
Found Python2: C:/Users/user/Desktop/paraview/buildvs2015/install/lib/python27.lib (found suitable version "2.7.15", minimum required is "2.7") found components: Development
Found OpenGL: opengl32 found components: OpenGL
Found ZLIB: C:/Users/user/Desktop/paraview/buildvs2015/install/lib/zlib.lib (found version "1.2.11")
Looking for pthread.h
Looking for pthread.h - not found
Found Threads: TRUE
Skipping example: Clone1 example requires PARAVIEW_USE_QT to be enabled. Please rebuild ParaView (or point to a different build of ParaView) with PARAVIEW_USE_QT set to TRUE
Configuring done
I have ENABLE_qt5 and USE_SYSTEM_qt5 activated, why am I getting this? How can I fix it?
Use the Clone1 example from ParaView 5.7.0, not from master.
You can find the sources in
C:\Users\user\Desktop\paraview\buildvs2015\superbuild\paraview\src\Examples\CutstomApplications\Clone1

How to tell Visual Studio Code compiled from source where to find sqlite module?

I am building the Visual Studio Code from the source checked out from the git repository:
git clone https://github.com/microsoft/vscode
I am building using:
export NODE_OPTIONS=--max_old_space_size=2048
./scripts/npm.sh install --arch=armhf
./scripts/code.sh
I am using node 10.16.3 on a Raspberry PI 4, using Raspbian buster
There were no errors during build.
The installation downloads a precompiled version of electron on the first run.
However each time I try and run code, it starts but with an error:
[storage state.vscdb] open(): Unable to open DB due to Error: Cannot find module '../build/Release/sqlite
If I look in node_modules/vscode-sqlite3/build/Release/
I can see:
sqlite3.a
sqlite.a
It is unclear to me why electron/vscode cannot find this library. I would be greatful for any pointers on how to tell the runtime where to look for the modules.
On inspecting the build scripts and after many painful experiments, I've found and solved the 2 problems leading to this error.
The fact that .a static libraries are left behind hinted that some settings in the binding.gyp, config.gpy and/or makefiles are wrong, as Native Node Modules are normally dynamic libraries with an .node extension. One conditional line in the binding.gyp file under vscode-sqlite3 seems to the the culprit:
...
["target_arch=='arm'", {"type": "static_library"}]
...
Disable that line (by removing it or changing 'arm' to something else) and then run:
node-gyp configure
to regenerate the config.gpy file(s) under the build directory. Then build the module with:
node-gyp build
A sqlite.node will be generated in build/Release.
Unfortunately, the latest electron ABI version rarely matches that of the Node.js version. In my configuration, the electron ABI version is 72 (v6.0.12) but the latest stable Node version is for ABI 64. Therefore we have to do an electron-rebuild to update the sqlite.node to match the electron version.
To do this, you would have to first install electron-rebuild (yarn add electron-rebuild) then run electron-rebuild by giving supplying explicitly the version number of the electron binary that vscode downloaded:
electron-rebuild -v 6.0.12 -m /home/dev/vscode -o vscode-sqlite3
Of course you would have to state the version number of your particular version of electron you are building for.
(Please look up electron-rebuild --help for the meaning of the options. It takes a while to rebuild the binary module...)
The resulting sqlite.node can then be moved into the build/Release/. directory under the vscode project directory. Voila, we have a working latest version VS-Code for Raspbian!

Adding new kit for cross platform arm linux not appears when create a new project

I'm working with a DEBIAN OS that it have an enviroment configured to work with a cross platform arm device with yocto.
After following the provider instructions:
Set up OS env with a script
open qtcreator from a terminal with the custom enviroment
add a kit with custom qmake, gcc and gdb (there is no warning)
add the device sysroot & ip (all tests ok)
Seems like all is ok but when i try to apply this changes i receive the following message:
Failed to set up kit for Qbs: Could no determine whether Qt is a
static build.
and the kit is not appearing when i try to create a new project.
i already check this pages and all explained there is done:
http://doc.qt.io/qtcreator/creator-targets.html
https://support.emtrion.de/en/details_operating-systems/linux-37.html?file=files/content/emtrion/downloads/emLinux-documentation-v008en.pdf
any clue about what is going wrong here?
Thanks by your time.
EDIT
i'm using qt-creator 4.7 and the current configuration works properly at 4.2 version.
the Qt version used fot the kit give the follow message at both versions:
ABI detection failed: Make sure to use a matching compiler when building
here is an open post with a similar unsolved issue:
https://forum.qt.io/topic/88857/my-kit-isn-t-showing-up/15

kaa sample apps miss build files for c sdk

I have been researching kaa platform for weeks. And yesterday, I started running a sample application named gpiocontrol on kaa github. The java (android) sdk works fine. However, when trying to build the c sdk for esp8266, I find out some files are missing, which are
build.sh (Refered in readme file)
CMakelists.txt (Prompted when I tried to run cmake)
Also, I find these missing files in some previous commits of the project. So please check and re-add these files. Thank you very much kaa team.
Update
I do notice that the build files I mentioned above can be found in the /common path of the root directory (sample-apps).
Update 2
Unfortunately, the common build files does not have specific build files for esp8266 platform. Now I'm wondering which method should be used to build kaa for this platform, follow kaa documentation for esp8266 or just add the option -DKAA_PLATFORM=esp8266 to cmake command in common build.sh file? Actually, I have tried the second way but it failed :(
The common build.sh file cmake command
build() {
mkdir -p "$PROJECT_HOME/build"
cd "$PROJECT_HOME/build"
cmake -DBUILD_TESTING=OFF ..
make
}
Still wait for your response and thank you again!
The sample applications' sources you have discovered in the sample-apps repository on GitHub are first assembled by Maven build tool and then deployed into Kaa Sandbox image.
This does most of the effort necessary to build the application(s) easily using Kaa Sandbox.
Thus, the most simple way to build and run Kaa sample applications is by downloading them from Kaa Sandbox through the web interface and then building according to the guide. The guide itself is available on the Kaa Sandbox web interface and is tested for each the application delivered with the Kaa Sandbox.
More information on using Kaa Sandbox is available in the official Kaa Getting started documentation.
Please let me know if using Kaa Sandbox is not an option for you and you still need to build the applications manually.
Update: I confirm the ESP8622 platform was disabled for the Kaa Sandbox 0.10.0 release due to some issues on that platform at the release time.
We are planning to release Kaa 0.10.1 with fixes that should include ESP8622 platform fixes soon.
Update 2: You can now use master branch of the kaaproject/sample-apps repository to build GPIO Control application for ESP8266 platform according to the below without need to wait for the next release:
Create a CMakeLists.txt file within the root directory of the application with the next content:
cmake_minimum_required(VERSION 3.0.2)
include(config.cmake)
if (NOT DEFINED KAA_MAX_LOG_LEVEL)
set(KAA_MAX_LOG_LEVEL 3)
endif (NOT DEFINED KAA_MAX_LOG_LEVEL)
set(BUILD_TESTING OFF CACHE BOOL "")
if (NOT DEFINED KAA_SDK_PATH)
add_subdirectory(libs/kaa)
else (NOT DEFINED KAA_SDK_PATH)
add_subdirectory(${KAA_SDK_PATH})
endif (NOT DEFINED KAA_SDK_PATH)
install(TARGETS demo_client DESTINATION bin)
Extract the Kaa SDK into libs/kaa directory.
Then run (formatted as single command):
mkdir build && \
cd build && \
cmake .. \
-DCMAKE_TOOLCHAIN_FILE=../libs/kaa/toolchains/esp8266.cmake \
-DKAA_PLATFORM=esp8266 && \
make

Cannot cmake kde-connect

I am trying to install kde-connect following this.
Although my kubuntu version is 14.04, I wanted to compile them so that I can have the latest version. But when I followed the instructions to compile, i get the following error.
-- Found Qt-Version 5.2.1 (using /usr/bin/qmake)
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
QT_QT_INCLUDE_DIR
used as include directory in directory /home/vinaychandra/Downloads/t/CMakeFiles/CMakeTmp
CMake Error: Internal CMake error, TryCompile configure of cmake failed
CMake Error at /usr/share/kde4/apps/cmake/modules/FindKDE4Internal.cmake:1311 (message):
Unable to compile a basic Qt application. Qt has not been found correctly.
Call Stack (most recent call first):
/usr/share/cmake-2.8/Modules/FindKDE4.cmake:95 (find_package)
CMakeLists.txt:7 (find_package)
Please point out how to correct this.
I have tried giving -DQT_QT_INCLUDE_DIR=/usr/share/qt4/
then it tells that You must build your code with position independent code if Qt was built with -reduce-relocations.
Your cmake by default uses a different QT version.
So, you must explicitly tell him which version of QT he have to use for this job.
This one
-DQT_QT_INCLUDE_DIR=/usr/share/qt4/
Is wrong because you mustn't give QT position explicitly.
All you need is to use the right qmake.
So, give'em this flag and you'll be happy!
-DQT_QMAKE_EXECUTABLE=/usr/bin/qmake-qt4
Since most of kde applications are not ported to Qt5, you need Qt4.x for building kdeconnect(don't know x, mine is 4.8.6).
Also Qt4 installer is not available (I think !), so you have to build it also from source. Building Qt4 is quite easy, just download the source and run the usual commands.
After building it, it qmake name will be qmake-qt4 in /usr/bin.
So for building kdeconnect, first run its cmake, then a Cmaketextcache.txt file will form.
In that change the path of qmake (i.e somewhere written /usr/bin/qmake to /usr/bin/qmake-qt4) and also the path of qt include dir to (I think /usr/include/qt5 to /usr/include/qt4), and run the cmake again.
If some packages are missing, then you have to install it.
But with the above changes, you will get a make file to install it.
Unfortunately, the cited documentation is lagging behind the current state of kdeconnect. I ran into similar problems but I managed to solve them by installing the following required packages from the Kubuntu repositories:
sshfs
libfakekey-dev
libxtst-dev
libqca2-dev
libqjson-dev
I trust these are all of them. I installed kdeconnect from the latest git commit and it seems to run fine.
This answer comes a bit late, but this is the first Google search result for the question. In systems with qtchooser (Kubuntu, Ubuntu at least), this can be fixed by running first:
export QT_SELECT=qt4
This makes all of the Qt build tools to default to the Qt4 version instead of Qt5. You can check which Qt version is active by running:
qmake --version
Try kde connect install on ubuntu: https://fazlerabbi37.github.io/blogs/install_kde_connect_in_ubuntu_18.04.html
(in 18.04 & 19.04 it works with simple sudo apt install kdeconnect
Install kde connect on android device (google play store is where I installed from)
Invoke kde connect from desktop
Invoke kde connect from android and search device.
Your ubuntu will be found / initiating a search from desktop results in android phone pulled up for pairing
Accept pairing request
Provide access to folders
Try clicking on a video/image file for transfer
I could see the new file transferring in /Downloads folder of desktop
allowing/disallowing desktop to access sms, notifications etc are now a choice
Note: Pl treat this with pinch of salt. This appears very simple, effective for a main reason it worked for me in no time.

Resources