Actually if you talk about the qmake.conf : this is not a problem as it's easy to change the paths to a different toolchain in there ( to point to -gcc -ld, etc) . I'd rather prefer to use the power of my PC to compile all and send binaries to the BBB . the ldd I have done was to show what were missing but at the end it was an arm format.
2014/1/13 Louis McCarthy <[email protected]> > As far as I know, the Angstrom toolchain comes with qmake for qt-embedded, > the Linaro toolchain does not, hence the reason for cross compiling Qt. > > When you cross compile Qt, you end up with an installation folder (like > /opt/qt or /usr/local/qt). This folder is where you point Qt Creator (Tools > -> Options -> Build & Run -> Qt Versions). Qt Creator can then use the > qmake executable, under the bin folder, to create your application to run > on the BBB. > > In fact, you shouldn't need to compile the whole Qt project, just enough > of the qmake tools to build apps to match the Qt version already installed > on the BBB. > > Running 'ldd <app_name>' on your host will result in "not a dynamic > executable", because it is an ARM binary. But if you transfer the binary > file to the BBB and run ldd again it will show you the proper output. > > Louis > > On Monday, January 13, 2014 9:31:27 AM UTC-6, dlewin555 wrote: > >> Mirko : >> Thanks for your answer. >> Actually, I left Angstrom for a while ( independantly that it's going to >> be replaced by Debian) so intend to use Debian instead. Nevertheless, I >> suppose that it's not far from what you have done with Angstrom anyway. >> >> >> >> >> >> >> 2014/1/13 Mirko Fucci <[email protected]> >> >>> >>> I experienced a simpler way to work with qt embedded for BBB following >>> Derek Tutorial >>> http://www.youtube.com/watch?v=kP7uvOu9hoQ where you don't need to >>> cross compile >>> QT: >>> >>> - install toolchain on your host >>> - install qt4-embedded on BBB (opkg install qt4-embedded - fors-depends >>> - create on your host a QT creator version from (/usr/local/angstrom/... >>> qmake2) >>> - create your kit to deploy app in BBB >>> >>> The only problem i had is that installing qt4-embedded i had no >>> linuxinput driver support for keyboard (because it'not in the default QT i >>> guess) >>> so i had to cross-compile qt as shown in Meir tutorial(http://www.cloud- >>> rocket.com/2013/07/building-qt-for-beaglebone/) with configure: >>> >>> ./configure -v -opensource -confirm-license -prefix /opt/qt -embedded >>> arm -platform qws/linux-x86-g++ -xplatform qws/linux-am335x-g++ -depths >>> 16,24,32 -no-mmx -no-3dnow -no-sse -no-sse2 -no-glib -no-cups -no- >>> largefile -no-accessibility -no-openssl -no-gtkstyle -qt-mouse-pc -qt- >>> mouse-linuxtp -qt-mouse-linuxinput -plugin-mouse-linuxtp -plugin-mouse- >>> pc -fast -little-endian -host-big-endian -no-pch -no-sql-ibase -no-sql- >>> mysql -no-sql-odbc -no-sql-psql -no-sql-sqlite -no-sql-sqlite2 -no- >>> webkit -no-qt3support -nomake examples -nomake demos -nomake docs -nomake >>> translations -qt-kbd-linuxinput >>> >>> then to make mouse and keyboard work you have copy plugins dir in >>> /opt/qt from your host to Beaglebone black and export like this before run >>> your app: >>> >>> QWS_MOUSE_PROTO = "LinuxInput:/dev/input/touchscreen0 >>> MouseMan:/dev/input/mouse1" Touchscreen and mouse >>> >>> QWS_KEYBOARD = "LinuxInput:/dev/input/event2 >>> LinuxInput:/dev/input/event3:keymap=.../it.qmap" LDC keys and my usb >>> keyboard mapped to italian layout >>> >>> QT_PLUGIN_PATH = "/opt/qt/plugins" needed for keyboard and MouseMan >>> drivers >>> >>> It was very but at the end everything works fine ! >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> Il giorno venerdì 10 gennaio 2014 22:18:22 UTC+1, [email protected] >>> scritto: >>> >>>> I used the instructions and got a working BBB with a CAP LCD7. However >>>> I needed to cut the eMMC lines to the LCD CAP (BeagleToys one), it is a A3 >>>> Ref but still did not work, but the site say is 100% BBB compatible.. ha ha >>>> . The only thing that does not work is the mouse when used with the LCD >>>> CAP, but that is not a problem to me as I used the touch screen. I made a >>>> document up with the instructions as I had to change some things to get the >>>> GUI , GDD and LCD cap working. >>>> >>>> I also think QT creator has a bug , one has to delete the xx.user file >>>> and then setup the kit, else you cannot change the kit, it still uses the >>>> original kit. So just be sure to select the correct kit when started after >>>> the .user file was was deleted. >>>> >>>> It works great !! >>>> >>>> >>>> Building and setting up QT environment for BeagleBone >>>> >>>> There are too few information available on how to easily setup QT >>>> environment for building Beaglebone applications (command line or GUI). In >>>> this tutorial we will compile QT and setup the environment from scratch. >>>> 1. My environment >>>> >>>> - >>>> >>>> Host: Ubuntu 13.10 64bit (VB) >>>> - >>>> >>>> Target: BeagleBone Black running Angstrom >>>> - >>>> >>>> QT: 4.8.5 >>>> >>>> 2. Setup Angstrom cross-compile toolchain for Linux >>>> >>>> Download : >>>> >>>> - >>>> >>>> angstrom-2011.03-x86_64-linux-armv7a-linux-gnueabi-toolchain >>>> >>>> -qte-4.6.3.tar.bz2<http://www.angstrom-distribution.org/toolchains/angstrom-2011.03-x86_64-linux-armv7a-linux-gnueabi-toolchain-qte-4.6.3.tar.bz2> >>>> for 64bit host or >>>> - >>>> >>>> angstrom-2011.03-i686-linux-armv7a-linux-gnueabi-toolchain- >>>> >>>> qte-4.6.3.tar.bz2<http://www.angstrom-distribution.org/toolchains/angstrom-2011.03-i686-linux-armv7a-linux-gnueabi-toolchain-qte-4.6.3.tar.bz2> >>>> for x86 (or download more recent version at >>>> >>>> http://www.angstrom-distribution.org/toolchains/). >>>> - >>>> >>>> https://googledrive.com/host/0B3Z340LOBulvMG5NRmNlZEppSEE >>>> >>>> Run >>>> >>>> $> tar -C / -xjf angstrom-2011.03-i686-linux-armv7a-linux-gnueabi- >>>> toolchain-qte-4.6.3.tar.bz2 >>>> 3. Download and un-tar QT >>>> >>>> > wget http://download.qt-project.org/official_releases/qt/4.8/4.8. >>>> 5/qt-everywhere-opensource-src-4.8.5.tar.gz >>>> >>>> > tar -xzf qt-everywhere-opensource-src-4.8.5.tar.gz >>>> >>>> > mv qt-everywhere-opensource-src-4.8.5 qt-4.8.5-beagle >>>> >>>> >>>> 4. Create qmake.conf >>>> >>>> > cd qt-4.8.5-beagle >>>> >>>> > mkdir ./mkspecs/qws/linux-am335x-g++ >>>> >>>> > cp ./mkspecs/qws/linux-arm-g++/qplatformdefs.h >>>> ./mkspecs/qws/linux-am335x-g++ >>>> >>>> > touch ./mkspecs/qws/linux-am335x-g++/qmake.conf >>>> >>>> >>>> Add the following to qmake.conf with your favorite editor: >>>> >>>> # >>>> >>>> # qmake configuration for building with arm-linux-g++ >>>> >>>> # >>>> >>>> include(../../common/linux.conf) >>>> >>>> include(../../common/gcc-base-unix.conf) >>>> >>>> include(../../common/g++-unix.conf) >>>> >>>> include(../../common/qws.conf) >>>> >>>> >>>> >>>> # modifications to g++.conf >>>> >>>> #Toolchain >>>> >>>> >>>> >>>> #Compiler Flags to take advantage of the ARM architecture >>>> >>>> QMAKE_CFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon >>>> -mfloat-abi=softfp >>>> >>>> QMAKE_CXXFLAGS_RELEASE = -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon >>>> -mfloat-abi=softfp >>>> >>>> >>>> >>>> QMAKE_CC = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/gcc >>>> >>>> QMAKE_CXX = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/g++ >>>> >>>> QMAKE_LINK = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/g++ >>>> >>>> QMAKE_LINK_SHLIB = /usr/local/angstrom/arm/arm-an >>>> gstrom-linux-gnueabi/bin/g++ >>>> >>>> >>>> >>>> # modifications to linux.conf >>>> >>>> QMAKE_AR = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/ar >>>> cqs >>>> >>>> QMAKE_OBJCOPY = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/ >>>> objcopy >>>> >>>> QMAKE_STRIP = /usr/local/angstrom/arm/arm-angstrom-linux-gnueabi/bin/ >>>> strip >>>> >>>> >>>> >>>> load(qt_config) >>>> 5. Configure QT embedded >>>> >>>> ./configure -v -opensource -confirm-license -prefix /opt/qt -embedded >>>> arm -platform qws/linux-x86-g++ -xplatform qws/linux-am335x-g++ -depths >>>> 16,24,32 -no-mmx -no-3dnow -no-sse -no-sse2 -no-glib -no-cups -no-largefile >>>> -no-accessibility -no-openssl -no-gtkstyle -qt-mouse-pc -qt-mouse-linuxtp >>>> -qt-mouse-linuxinput -plugin-mouse-linuxtp -plugin-mouse-pc -fast >>>> -little-endian -host-big-endian -no-pch -no-sql-ibase -no-sql-mysql >>>> -no-sql-odbc -no-sql-psql -no-sql-sqlite -no-sql-sqlite2 -no-webkit >>>> -no-qt3support -nomake examples -nomake demos -nomake docs -nomake >>>> translations -qt-mouse-tslib >>>> 6. Build and install >>>> >>>> > make -j 4 >>>> >>>> > sudo make install >>>> 7. Install Qt SDK (lib) we built previously on your board >>>> >>>> Make sure you beaglebone is connected to your host (assume ip >>>> =192.168.7.2 USB) >>>> >>>> - >>>> >>>> ssh to your beaglebone (ssh [email protected]) >>>> >>>> >>>> - >>>> >>>> Create dir structure from your prefix: >>>> >>>> > root@beaglebone:/# mkdir /opt >>>> >>>> >>>> > root@beaglebone:/# mkdir /opt/qt >>>> >>>> > opkg install tslib-calibrate >>>> >>>> > ts-all >>>> >>>> > ts-calibrate (calibrate all points) >>>> >>>> > update-rc.d -f gdm remove >>>> >>>> > systemctl disable gdm.service >>>> >>>> > reboot >>>> >>>> >>>> - >>>> >>>> Copy lib from your host to beagle (after reboot): >>>> >>>> > scp -r /opt/qt/lib [email protected]:"/opt/qt" >>>> - >>>> >>>> Add the lib directory to path by editing /etc/profile and adding: >>>> >>>> PATH="...:/opt/qt/lib" >>>> - >>>> >>>> NS run applications preceding with >>>> - >>>> >>>> export QWS_MOUSE_PROTO=LinuxInput:/dev/input/eventx >>>> >>>> Note x could be 0 or 1 depending on your setup >>>> >>>> AND >>>> - >>>> >>>> ./xxxxx -qws where xxxx is your application >>>> >>>> 8. Download, install and configure QT Creator >>>> >>>> I suggest installing QT Creator using regular installer: >>>> >>>> Download >>>> - >>>> >>>> >>>> qt-creator-linux-x86-opensource-2.8.0.run<http://download.qt-project.org/official_releases/qtcreator/2.8/2.8.0/qt-creator-linux-x86-opensource-2.8.0.run> >>>> for >>>> x86 or >>>> - >>>> >>>> >>>> qt-creator-linux-x86_64-opensource-2.8.0.run<http://download.qt-project.org/official_releases/qtcreator/2.8/2.8.0/qt-creator-linux-x86_64-opensource-2.8.0.run> >>>> for >>>> 64bit >>>> >>>> > chmod +x qt-creator-linux-x86_64-opensource-2.8.0.run >>>> /qt-creator-linux-x86_64-opensource-2.8.0.run >>>> - >>>> >>>> Follow installation Wizard >>>> - >>>> >>>> Run Angstrom toolchain environment setup: >>>> >>>> > . /usr/local/angstrom/arm/environment-setup >>>> >>>> Test with > qmake2 and see if it response without error(not >>>> existing) >>>> >>>> Open Qt Creator and >>>> - >>>> >>>> Configure *Qt version * >>>> >>>> >>>> 1. Go to Tools->Options->Build & Run->Qt Versions and click *Add * >>>> >>>> >>>> 2. Select qmake.conf from /opt/qt/bin >>>> >>>> >>>> 3. Click *Ok * >>>> >>>> >>>> - >>>> >>>> Configure target *device connection* >>>> >>>> >>>> 1. Go to Tools->Options->Devices >>>> >>>> >>>> 2. Click Add and select *Generic Linux Device * >>>> >>>> >>>> 3. Add IP 192.168.7.2, User: root >>>> >>>> >>>> 4. Set name to “Beaglebone” >>>> >>>> >>>> 5. Click Ok >>>> >>>> >>>> - >>>> >>>> Configure *Compiler * >>>> >>>> >>>> 1. Go to Tools->Options->Build & Run->Compilers and click Add->GCC >>>> >>>> >>>> 2. Select compiler path: >>>> /usr/local/angstrom/arm/bin/arm-angstrom-linux-gnueabi-g++ >>>> >>>> >>>> >>>> 3.Click Ok >>>> >>>> >>>> - >>>> >>>> Configure* Kit * >>>> >>>> >>>> 1. Go to Tools->Options->Build & Run->Kits and click Add >>>> >>>> >>>> 2. Call new kit Beaglebone >>>> >>>> >>>> 3. Select device type: “Generic Linux Device” >>>> >>>> >>>> 4. Select the device you previously created >>>> >>>> >>>> 5. Select compiler you created >>>> >>>> >>>> 6. Select Qt version you created >>>> >>>> >>>> - >>>> >>>> Select GDK path as /usr/local/angstrom/arm/bin/arm-angstrom-linux- >>>> gnueabi-gdk >>>> >>>> >>>> 1. Click Ok (not found !! ) >>>> - >>>> >>>> Configure GDB >>>> >>>> 1 Goto Tools > Options > Build & Run, >>>> >>>> 2. set Debugger > Edit to /usr/local/angstrom/arm/bin/ar >>>> m-angstrom-linux-gnueabi-gdb >>>> >>>> 9. Build Qt application >>>> >>>> - >>>> >>>> Create new project (File->New project->Qt Project->Qt Console >>>> application) >>>> - >>>> >>>> Edit your project (.pro) file >>>> - >>>> >>>> Add the following after “TARGET=…” line: >>>> >>>> target.files = <YOUR EXECUTABLE NAME> >>>> >>>> >>>> target.path = /home/root >>>> >>>> >>>> INSTALLS = target >>>> - >>>> >>>> Go to Projects -> Run, you should see on “Files to deploy” table >>>> your “target” settings >>>> >>>> >>>> - >>>> >>>> Now you are ready to build and deploy you project on your target >>>> board >>>> >>>> >>>> - >>>> >>>> The following example application should print Hello world inside >>>> your console: >>>> >>>> #include <QCoreApplication> >>>> >>>> #include <iostream> >>>> >>>> >>>> int main(int argc, char *argv[]) >>>> >>>> { >>>> >>>> QCoreApplication a(argc, argv); >>>> >>>> std::cout << "hello world" << std::endl; >>>> >>>> return a.exec(); >>>> >>>> } >>>> >>>> >>>> >>>> >>>> -- >>> For more options, visit http://beagleboard.org/discuss >>> --- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "BeagleBoard" group. >>> To unsubscribe from this topic, visit https://groups.google.com/d/ >>> topic/beagleboard/mb1R6NF5RH4/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> [email protected]. >>> >>> For more options, visit https://groups.google.com/groups/opt_out. >>> >> >> -- > For more options, visit http://beagleboard.org/discuss > --- > You received this message because you are subscribed to a topic in the > Google Groups "BeagleBoard" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/beagleboard/mb1R6NF5RH4/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
