Re: [SailfishDevel] Connman OpenVPN
Op zondag 5 januari 2014 01:59:29 schreef Matthias Fulz: > Hi, > > I'm working on a OpenVPN client for my Jolla, but it seems that connman is > bugging around here: > > this is the comman which will be used by connman: > > openvpn --remote olz.dyndns.org --ca /home/nemo/OpenVPN/ca.crt --cert > /home/nemo/OpenVPN/olz_mobile.crt --key /home/nemo/OpenVPN/olz_mobile.key -- > comp-lzo --nobind --persist-key --client --script-security 2 --up > /usr/lib/connman/scripts/openvpn-script --up-restart --setenv > CONNMAN_BUSNAME > :1.71 --setenv CONNMAN_INTERFACE net.connman.Task --setenv CONNMAN_PATH > > /task/0 --dev vpn0 --dev-type tun --persist-tun --route-noexec --ifconfig- > noexec --ping-restart 0 > > As it wasn't able to connect I've tried to run this command on my own: > > [root@localhost OpenVPN]# openvpn --remote olz.dyndns.org --ca > /home/nemo/OpenVPN/ca.crt --cert /home/nemo/OpenVPN/olz_mobile.crt --key > /home/nemo/OpenVPN/olz_mobile.key --comp-lzo --nobind --persist-key --client > --script-security 2 --up /usr/lib/connman/scripts/openvpn-script > --up-restart --setenv CONNMAN_BUSNAME :1.71 --setenv CONNMAN_INTERFACE > net.connman.Task -- setenv CONNMAN_PATH /task/0 --dev vpn0 --dev-type tun > --persist-tun --route- noexec --ifconfig-noexec --ping-restart 0 > Sun Jan 5 01:41:41 2014 OpenVPN 2.2.2 armv7l-unknown-linux-gnueabi [SSL] > [LZO2] [EPOLL] [PKCS11] [eurephia] built on Nov 1 2013 > Sun Jan 5 01:41:41 2014 WARNING: No server certificate verification method > has been enabled. See http://openvpn.net/howto.html#mitm for more info. > Sun Jan 5 01:41:41 2014 NOTE: the current --script-security setting may > allow this configuration to call user-defined scripts > Sun Jan 5 01:41:41 2014 LZO compression initialized > Sun Jan 5 01:41:42 2014 UDPv4 link local: [undef] > Sun Jan 5 01:41:42 2014 UDPv4 link remote: 188.194.98.162:1194 > Sun Jan 5 01:42:17 2014 [olz.dyndns.org] Peer Connection Initiated with > 188.194.98.162:1194 > Sun Jan 5 01:42:20 2014 TUN/TAP device vpn0 opened > Sun Jan 5 01:42:20 2014 /usr/lib/connman/scripts/openvpn-script vpn0 1500 > 1542 192.168.100.202 192.168.100.201 init > Sun Jan 5 01:42:20 2014 Initialization Sequence Completed > > The issue is related to the script: > > /usr/lib/connman/scripts/openvpn-script > > which just seems to do nothing. > > When I'm just removing the options: > > --route-noexec --ifconfig-noexec > > from the command above it is connecting fine: > > Sun Jan 5 01:57:32 2014 OpenVPN 2.2.2 armv7l-unknown-linux-gnueabi [SSL] > [LZO2] [EPOLL] [PKCS11] [eurephia] built on Nov 1 2013 > Sun Jan 5 01:57:32 2014 WARNING: No server certificate verification method > has been enabled. See http://openvpn.net/howto.html#mitm for more info. > Sun Jan 5 01:57:32 2014 NOTE: the current --script-security setting may > allow this configuration to call user-defined scripts > Sun Jan 5 01:57:32 2014 LZO compression initialized > Sun Jan 5 01:57:33 2014 UDPv4 link local: [undef] > Sun Jan 5 01:57:33 2014 UDPv4 link remote: 188.194.98.162:1194 > Sun Jan 5 01:58:07 2014 [olz.dyndns.org] Peer Connection Initiated with > 188.194.98.162:1194 > Sun Jan 5 01:58:10 2014 TUN/TAP device vpn0 opened > Sun Jan 5 01:58:10 2014 /sbin/ip link set dev vpn0 up mtu 1500 > Sun Jan 5 01:58:10 2014 /sbin/ip addr add dev vpn0 local 192.168.100.202 > peer 192.168.100.201 > Sun Jan 5 01:58:10 2014 /usr/lib/connman/scripts/openvpn-script vpn0 1500 > 1542 192.168.100.202 192.168.100.201 init > RTNETLINK answers: File exists > Sun Jan 5 01:58:10 2014 ERROR: Linux route add command failed: external > program exited with error status: 2 > Sun Jan 5 01:58:10 2014 Initialization Sequence Completed > > ifconfig: > > vpn0 Link encap:UNSPEC HWaddr > 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 > inet addr:192.168.100.202 P-t-P:192.168.100.201 > Mask:255.255.255.255 > UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1 > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 txqueuelen:100 > RX bytes:0 (0.0 b) TX bytes:0 (0.0 b) > > > Is this a bug inside connman or jolla? Could anyone help in finding a > solution? looks like connman adds these options so that it can use it's internal process of setting ip and adding routes, possibly due to user vs root rights? but somehow it's failing? ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Check for OS in .PRO file
I use similar approach, but I do qmake CONFIG+=sailfish and then I can check for it in the .pro file like this: sailfish { DEFINES += Q_OS_SAILFISH ... } Looks shorter and cleaner to me :-) On 03.01.2014 12:21, Timur Kristóf wrote: Hi, What Thomas said makes sense, I just want to add one more little thing. You can, in the .spec file, add stuff to qmake, like this define. This would make the necessary code shorter and as a bonus, it gives you something you can even ifdef in C++. # spec file qmake DEFINES+=IS_SAILFISH_OS # pro file contains(DEFINES, IS_SAILFISH_OS) { ... } // C++ file #if defined(IS_SAILFISH_OS) ... #endif Cheers, Timur Timur On Thu, Jan 2, 2014 at 8:44 PM, Thomas Perl mailto:th.p...@gmail.com>> wrote: Hi, On 02 Jan 2014, at 20:25, Sven Putze mailto:sailfish...@hardcodes.de>> wrote: > There are ways to check for the OS in QtCreator .PRO files, e.g. like > > unix:symbian{ # do stuff} > unix:maemo5{ # do stuff} > macx{ # do stuff} > win32{ # do stuff} > > Is there a way to check (or control to be more precise) that some directives are only used when compiling on the MerSDL VM? > Just checking for the presence of "sailfishapp" does not work, because that is defined for any OS. In general, it might just be easier (and more maintainable) to have a per-platform .pro file for your project and not litter your .pro file with lots of conditionals (been there, done that - it will become hard to read, understand and maintain as the number of platforms grows). If there’s a lot of common things that you need in each file, put that in a .pri file and include it in each platform-specific .pro file. Then, in the sailfish .spec, you can call qmake on the sailfish-specific project file, in the Maemo 5 debian/rules script, you call qmake on the maemo5 .pro file, etc… With that said, you can use packagesExist[1] to do sailfish-specific things if you are convinced that a single .pro file really is the way to go: packagesExist(sailfishapp) { .. do stuff .. } Alternatively, set an environment variable in the qmake call in the .spec file and check for that variable in the .pro file: # In the .spec file: IS_SAILFISH_OS=1 qmake # In the .pro file: IS_SAILFISH_OS = $$(IS_SAILFISH_OS) contains(IS_SAILFISH_OS, 1) { .. do stuff .. } HTH :) Thomas [1] http://qt-project.org/doc/qt-4.8/qmake-function-reference.html#packagesexist-packages -- With best regards, Oleksii Serdiuk smime.p7s Description: S/MIME Cryptographic Signature ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Undocumented Silica components
They're not documented because they might not be ready for prime time yet or their API might still change. So I'd be careful using them. On 03.01.2014 12:26, Timur Kristóf wrote: Hi Luciano, My guess is that since those components are part of Silica and their imports are allowed in the harbour, it is OK to use them. I don't know their actual official status but I guess they are simply not documented because of a mistake, not because they are disallowed. Would be nice to have someone from Jolla confirm, though. Cheers, Timur Timur On Thu, Jan 2, 2014 at 9:58 PM, Luciano Montanaro mailto:mikel...@gmail.com>> wrote: I don't know if this has been addresed already, but... In my application, I would like to use a few components that the componentgallery is demoing, but that are not documented in the reference documentation. Is it OK to use everything that works there? Specifically, I want to use * OpacityRampEffect for my coverpage * the busy property of the PullDownMenu while fetching status updates * possibly the GlassItem as an indicator of the train delay Since I would like for my application to eventually be distributed through the Harbour, I would like to know if it is OK to do so. Best regards, Luciano -- With best regards, Oleksii Serdiuk smime.p7s Description: S/MIME Cryptographic Signature ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] ContextMenu with repeater
Did you try using `model.index` instead of just `index`? Are you sure that onClicked signal in MenuItem gets fired? On 03.01.2014 16:21, Andrey Kozhevnikov wrote: Hello I can't get context menu index if using repeater inside ComboBox { id: languageCombo label: "Language" currentIndex: 0 menu: ContextMenu { id: languageMenu Repeater { width: parent.width model: localeNames delegate: MenuItem { text: modelData onClicked: { console.log("selected: " + modelData) console.log("selected: " + index) } } } onActiveChanged: { console.log("index: " + languageCombo.currentIndex) } } onCurrentIndexChanged: { if (languageMenu.active) { console.log(index: " + currentIndex) } } } No output is produced when i selecting item, but item in repeater changed. -- With best regards, Oleksii Serdiuk smime.p7s Description: S/MIME Cryptographic Signature ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] ContextMenu with repeater
I solved it. If context menu length > 6 it becomes dialog, and after choosing dialog item fired only onItemChanged signal, not onIndexChanged. With short combobox everything fine :) You can mark it as found bug ;) On 05.01.2014 18:15, Oleksii Serdiuk wrote: Did you try using `model.index` instead of just `index`? Are you sure that onClicked signal in MenuItem gets fired? On 03.01.2014 16:21, Andrey Kozhevnikov wrote: Hello I can't get context menu index if using repeater inside ComboBox { id: languageCombo label: "Language" currentIndex: 0 menu: ContextMenu { id: languageMenu Repeater { width: parent.width model: localeNames delegate: MenuItem { text: modelData onClicked: { console.log("selected: " + modelData) console.log("selected: " + index) } } } onActiveChanged: { console.log("index: " + languageCombo.currentIndex) } } onCurrentIndexChanged: { if (languageMenu.active) { console.log(index: " + currentIndex) } } } No output is produced when i selecting item, but item in repeater changed. ___ SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
[SailfishDevel] SDK / Deploy / Problem with subprojects
Hi there, let's assume I've got an umbrella project file myApp.pro which is in some BaseDir: TEMPLATE = subdirs SUBDIRS = myAppLogic myAppSFOS CONFIG += ordered myAppSFOS.depends = myAppLogic There are 2 subprojects, first there is myAppLogic which builds a library, second is myAppSFOS which builds the application for SailfishOS/Jolla device. myAppSFOS.pro has all the needed information about the library, so it should be put in the right place if one calls 'make install'. So far so good. All compiles well and then comes the deploy part. Regardless of the deployment method I get the following error message: Fatal: No spec file found in 'BaseDir/rpm/' and couldn't make one from a yaml Well, yes that's true - no .yaml file there. It should look at BaseDir/myAppSFOS/rpm/ Is this a bug in the SDK? (as in we are using a hardcoded path here) Am I doing it wrong? Can I somehow tell the deploy process where to look? BR. Sven P.S.: it's somehow related to the topics "[SailfishDevel] adding libraries to sailfish app." and ''Project tries to use spec file from another project" but I decided not to hijack them. ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Qt Creator Yaml file editor loses new entries
Hi, IMHO the .yaml file is (partly) rewritten if something changes in your .pro file, could this be your problem here? BR. Sven On 29.12.2013, at 17:48, christopher.l...@thurweb.ch wrote: > Hi All > > If add a new dependency to the a projects .yaml file via the QtCreator yaml > file editor, then immediately hit "cmd S" to save the changes, then more > often than not the new entry vanishes, and i have to repeat the process. > > So far I have not established exactly what pattern of circumstances is > required for this to happen / not happen (e.g. focus still on new entry), and > I now always double check after every save. > > I am running the very latest SDK on OSX. > > Chris > > > ___ > SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
[SailfishDevel] Is pragmatically taking a screenshot possible?
Hi folks, Is it technically possible to create an app that can take a screenshot of the home screen or device viewport? It is for the purpose of creating something technologically similar to a water screen saver. It is possible in rooted Android phones, via the NDK, with /dev/graphics/fb0 . Tutorial here: http://www.pocketmagic.net/2010/11/android-native-screen-capture-application-using-the-framebuffer/#.UkVXCniZilM Any help appreciated. ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] SDK / Deploy / Problem with subprojects
Op zondag 5 januari 2014 14:10:22 schreef Putze Sven: > Hi there, > > let's assume I've got an umbrella project file myApp.pro which is in some > BaseDir: > > TEMPLATE = subdirs > SUBDIRS = myAppLogic myAppSFOS > CONFIG += ordered > myAppSFOS.depends = myAppLogic > > There are 2 subprojects, first there is myAppLogic which builds a library, > second is myAppSFOS which builds the application for SailfishOS/Jolla > device. myAppSFOS.pro has all the needed information about the library, so > it should be put in the right place if one calls 'make install'. So far so > good. All compiles well and then comes the deploy part. > > Regardless of the deployment method I get the following error message: > Fatal: No spec file found in 'BaseDir/rpm/' and couldn't make one from a > yaml > > Well, yes that's true - no .yaml file there. It should look at > BaseDir/myAppSFOS/rpm/ Is this a bug in the SDK? (as in we are using a > hardcoded path here) Am I doing it wrong? Can I somehow tell the deploy > process where to look? > > > BR. > Sven > > > P.S.: it's somehow related to the topics "[SailfishDevel] adding libraries > to sailfish app." and ''Project tries to use spec file from another > project" but I decided not to hijack them. (as a side-question-hijack, does this generate on srpm that makes multiple rpms?) ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Qt Creator Yaml file editor loses new entries
Hi Sven I am not sure. The vanishing happens as soon as I hit command S (to save the changes). Chris Zitat von "Putze Sven" : Hi, IMHO the .yaml file is (partly) rewritten if something changes in your .pro file, could this be your problem here? BR. Sven On 29.12.2013, at 17:48, christopher.l...@thurweb.ch wrote: Hi All If add a new dependency to the a projects .yaml file via the QtCreator yaml file editor, then immediately hit "cmd S" to save the changes, then more often than not the new entry vanishes, and i have to repeat the process. So far I have not established exactly what pattern of circumstances is required for this to happen / not happen (e.g. focus still on new entry), and I now always double check after every save. I am running the very latest SDK on OSX. Chris ___ SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
[SailfishDevel] File not found errors while generating rpms: how can I fix them?
Hi, After having transformed my app, because I started it with the template that was shipping with the first version of the SDK, to use the new template, I think there are still some things to be fixed in .pro or .yaml When I try to deploy my app using "Deploy as RPM package" I get these errors: http://pastebin.com/qJv9L1cA I think the problem is in the .pro or in the .yaml and you can find both files (and also the full source code) here: - https://github.com/andreagrandi/sailsoma/blob/newtemplate/rpm/harbour-sailsoma.yaml - https://github.com/andreagrandi/sailsoma/blob/newtemplate/harbour-sailsoma.pro I've tried to give a look around to other projects but I cannot understand the differences (or better... ALL projects seem to be different from each other and use different conventions... it would not be better to use all the same convention and having QtC to check what's missing in .pro and .yaml for us?). It's a bit frustrating the fact that I'm spending more time to make project/packaging/deployment work instead of coding the app :( Thanks for your help. Cheers. -- Andrea Grandi - Software Engineer / Qt Ambassador / Nokia Developer Champion website: http://www.andreagrandi.it ___ SailfishOS.org Devel mailing list
[SailfishDevel] Possible to play video with gst-launch?
I'm trying to play a video with gst-launch like this: gst-launch-0.10 playbin2 uri=file:///home/nemo/file.avi but it doesn't seem to show any pictures, sound is working though. Am I missing something, like another video sink, or is this not possible? Greets Jens ___ SailfishOS.org Devel mailing list
[SailfishDevel] Creating advanced keyboard layouts with custom input handlers
Hi, I've been trying to experiment with creating more advanced keyboard layouts than ones who simply map one key to one character---more along the lines of the Chinese pinyin layout. To that end, I've been investigating the relevant QML files located in /usr/share/maliit/plugins/com/jolla/, and I think that I've got a decent idea of how they work. In essence, I need to create a custom input handler that, instead of querying the Xt9 library for potential candidates, implements its own logic. However, here I've hit a bit of a snag. Whenever the keyboard is started it seems to default to the standard InputHandler input handler, but almost immediately after starting, as well as (as far as I can tell) every time canvas.layoutRow.switchLayout is called, something somewhere changes the input handler to the Xt9InputHandler. If the layout is changed to the Chinese pinyin layout, though, the Xt9CpInputHandler is used instead, thanks to the magic value "china_pinyin" specified in the type attribute of the Chinese keyboard layout (zh_cn_pinyin.qml). However, from what I can see there's no straightforward way for a layout to specify a custom input handler---the Chinese input handler being hard coded. Am I overlooking something? Is it in fact possible to tell the keyboard to switch to a specified input handler upon loading a layout? If not, is it possible to tell the keyboard *not* to switch to the Xt9InputHandler? If I for instance try to set keyboard.inputHandler to an InputHandler in the Component.onCompleted attribute in en.qml, I can see how the input handler is changed for a fraction of a second before being changed again to the Xt9InputHandler. And I'm not sure if there's any non-ugly way to make sure that my code changing the input handler to my custom handler is instead run immediately after the code that switches the handler to the Xt9InputHandler has finished running. As an aside, would it be possible for a custom layout to register itself without having to edit layout.conf? That would make it much easier to provide the layout in the form of a simple RPM package. Regards, Arvid ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] No inbox?
On Thu, 2 Jan 2014 11:18:45 + Chris Walker wrote: > On Thu, 02 Jan 2014 12:50:08 +0200 > Jonni Nakari wrote: > > > On 02.01.2014 12:23, Chris Walker wrote: > > > As I appear to be the only one with this problem, it's plainly not > > > something that should trouble the development team. > > I had a similar problem when I tried adding my free Gmail account > > using Microsoft Exchange account type. No errors were displayed when > > creating the account or checking mail. > > > > I might have also seen this problem when I mistyped some settings on > > a imap type account, but not sure about that. > > > > I suggest that you re-create and double check all you account's > > settings. You might get some additional debug information by > > enabling the developer mode and running "journalctl -f -a" as root > > when first saving the account and when checking for new mail. > > This is an IMAP account. > > It is now declaring 'Problem with sync' so that does suggest a typo > somewhere but I have checked and rechecked all the account > information. I'm tempted to take a look at the accounts.db file to > see what that holds. I'm almost at the stage of throwing this thing away! It is *so* frustrating to use that it beggars belief at times. If I'm in the middle of setting up an email account and the screen blanks (after 5 seconds and not the 30 seconds it's set to!), why when I double tap to get back, does it revert to the home screen? I expect it to be like most other equipment I've used, phones included and to go back to where I left it. But the real frustration is the email setting stuff. I *still* haven't managed to get the thing to log into my IMAP account despite the fact that I can do it on a Windows 7 machine, the linux machine, a Blackberry Playbook and my N900 phone. They *all* show all the folders on the IMAP account and yet the Jolla won't. I've created the account countless times, both by ssh'ing in and doing it by the command line and also by using the GUI. It always displays 'Problem with Sync'. So as I also have an email account on the Playbook I used those settings and I can see all the folders that are present on that account (also IMAP). But having received an email into it, when I replied it wouldn't send. I *think* that initially was a problem with my router for some reason so having toggled the power to that I tried again. The message in the outbox would not send despite using the same settings as the PB. So I switched the settings on the Jolla to use the smtp server specified for my landline (the same that the linux and Windows machine use) but it still wouldn't send. I deleted the reply and recreated it and this time it did go. To me, that implies that the message holds details of the outgoing server and whatever I did, is never likely to make it send. So some questions. How can I reduce the number of accounts held in the sqlite database as the number is already up to 7 and I only have 2 email accounts, one of which doesn't work and the other one will be deleted? Second question. Does the email hold details of the outgoing server until it's sent? [I do see messages in the terminal 'OfonoNetworkRegistration' there was more to that but it's scrolled off screen too far to recall]. Third question and one that's been posed here before and that is, how do I set the password for IMAP from the command line without using push2mail and also, I would also like to be able to check the password. Is there any way? CDW ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] File not found errors while generating rpms: how can I fix them?
El Sunday 05 January 2014, a.gra...@gmail.com escribió: > - > https://github.com/andreagrandi/sailsoma/blob/newtemplate/rpm/harbour-sails > oma.yaml - > https://github.com/andreagrandi/sailsoma/blob/newtemplate/harbour-sailsoma. > pro Have you fixed that already? Because those URLs are 404 now. You deleted the branch? > I've tried to give a look around to other projects but I cannot understand > the differences (or better... ALL projects seem to be different from each > other and use different conventions... Because not all projects are the same, and because not all projects are developed by the same people. > it would not be better to use all > the same convention and having QtC to check what's missing in .pro and > .yaml for us?). That's even harder, and worse. You could define some high level project that would generate a .pro file, but once you generate the project file, you would end up needing to modify the .pro anyways. And you would need extra documentation for the added layer. I suggest you that you try to be patient, and don't try to learn all it at the same time. QMake is not awesome, and is not the best documented thing in the world, but is manageable, and for the use case of the majority of Sailfish developers, is not harder that doing the application itself. The problem is that one very quickly wants to do that, and at the same time do the packaging, which is another step, and is not necessarily well documented (IMHO) compared to qmake. If you can, try making your application work on the desktop as well. At least make it compile and install, so you can try simply if all files get copied to where you want. Then you can start blaming RPM or the packaging infrastructure if something doesn't work. Otherwise, without good knowledge of any of the two sides (building and packaging), you are shooting with your eyes closed. -- Alex (a.k.a. suy) | GPG ID 0x0B8B0BC2 http://barnacity.net/ | http://disperso.net ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] File not found errors while generating rpms: how can I fix them?
Hi, yes I deleted the branch because another person on #sailfishos suggested me how to fix the problem. I merged the branch with master and deleted the branch. You can find the whole source code here https://github.com/andreagrandi/sailsoma but to be quick it was a matter of putting all the qml files under qml/ and removing some stuff from the .pro Thanks in any case :) On 5 January 2014 18:48, Alejandro Exojo wrote: > El Sunday 05 January 2014, a.gra...@gmail.com escribió: > > - > > > https://github.com/andreagrandi/sailsoma/blob/newtemplate/rpm/harbour-sails > > oma.yaml - > > > https://github.com/andreagrandi/sailsoma/blob/newtemplate/harbour-sailsoma > . > > pro > > Have you fixed that already? Because those URLs are 404 now. You deleted > the > branch? > > > I've tried to give a look around to other projects but I cannot > understand > > the differences (or better... ALL projects seem to be different from each > > other and use different conventions... > > Because not all projects are the same, and because not all projects are > developed by the same people. > > > it would not be better to use all > > the same convention and having QtC to check what's missing in .pro and > > .yaml for us?). > > That's even harder, and worse. You could define some high level project > that > would generate a .pro file, but once you generate the project file, you > would > end up needing to modify the .pro anyways. And you would need extra > documentation for the added layer. > > I suggest you that you try to be patient, and don't try to learn all it at > the > same time. QMake is not awesome, and is not the best documented thing in > the > world, but is manageable, and for the use case of the majority of Sailfish > developers, is not harder that doing the application itself. > > The problem is that one very quickly wants to do that, and at the same > time do > the packaging, which is another step, and is not necessarily well > documented > (IMHO) compared to qmake. > > If you can, try making your application work on the desktop as well. At > least > make it compile and install, so you can try simply if all files get copied > to > where you want. Then you can start blaming RPM or the packaging > infrastructure > if something doesn't work. Otherwise, without good knowledge of any of the > two > sides (building and packaging), you are shooting with your eyes closed. > > -- > Alex (a.k.a. suy) | GPG ID 0x0B8B0BC2 > http://barnacity.net/ | http://disperso.net > ___ > SailfishOS.org Devel mailing list > -- Andrea Grandi - Software Engineer / Qt Ambassador / Nokia Developer Champion website: http://www.andreagrandi.it ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Possible to play video with gst-launch?
Hi, I think the default(?) sink used by gst-launch is not working (says something about video/x-android-buffer) . I can hear audio but no video with gst-launch. In QML using MediaPlayer and GStreamerVideoOutput is the only way i've got working output. For some reason VideoOutput doesn't work too. Br, Jarkko On Sun, Jan 5, 2014 at 4:27 PM, Jens Persson wrote: > I'm trying to play a video with gst-launch like this: > > gst-launch-0.10 playbin2 uri=file:///home/nemo/file.avi > > but it doesn't seem to show any pictures, sound is working though. Am I > missing something, like another video sink, or is this not possible? > > Greets Jens > > ___ > SailfishOS.org Devel mailing list > ___ SailfishOS.org Devel mailing list
[SailfishDevel] Build engine woes: rsync between /srv/ and /host_targets/ is having problems..
Hi, I've been having this mystery problem where Qt Creator complains about missing QML types. Like EnterKey, CoverListAction, CoverBackround etc. I even tried reinstalling the SDK but the problem remains. While investigation this issue I noticed that /usr/bin/sdk-manage --target --sync SailfishOS-armv7hl (also available in Qt Creator / SailfishOS/Targets/manage/sync is not working reliably. Between runs I noticed that some files (mainly those that QtC was complaing about being missing) are not actually rsynced ( rsync -a --no-devices --no-specials --delete --ignore-errors --prune-empty-dirs --copy-links --filter=. - /srv/mer/targets/SailfishOS-armv7hl/. /host_targets/SailfishOS-armv7hl/. ) In Build engine terminal: -bash-3.2$ sudo /usr/bin/sdk-manage --target --sync SailfishOS-armv7hl -bash-3.2$ find /srv/ -name EnterKey.qml /srv/mer/targets/SailfishOS-armv7hl/usr/share/maliit/plugins/com/jolla/EnterKey.qml -bash-3.2$ find /host_targets/ -name EnterKey.qml -bash-3.2$ <--- NOT found ? -bash-3.2$ find /srv/ -name ScreenBlank.qml /srv/mer/targets/SailfishOS-armv7hl/usr/lib/qt5/qml/Sailfish/Media/ScreenBlank.qml -bash-3.2$ find /host_targets/ -name ScreenBlank.qml /host_targets/SailfishOS-armv7hl/usr/lib/qt5/qml/Sailfish/Media/ScreenBlank.qml ScreenBlank was found even it was missing earlier, weird... Also notice that SailfishOS-i486-x86 is missing both files.. And this was fresh SDK installation. Anyone noticed something similar? br; Jarkko ___ SailfishOS.org Devel mailing list
[SailfishDevel] Cannot access phone book on phone when starting app from QtCreator
Hi, I am unable to access the phone book when running my app from QtCreator on the phone. Is this a security feature ? Is it possible to work with a fake contact DB ? Ciao Matze ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Connman OpenVPN
On Sunday 05 January 2014 01:59:29 Matthias Fulz wrote: > Hi, > > I'm working on a OpenVPN client for my Jolla, but it seems that connman is > bugging around here: > > this is the comman which will be used by connman: > > openvpn --remote olz.dyndns.org --ca /home/nemo/OpenVPN/ca.crt --cert > /home/nemo/OpenVPN/olz_mobile.crt --key /home/nemo/OpenVPN/olz_mobile.key -- > comp-lzo --nobind --persist-key --client --script-security 2 --up > /usr/lib/connman/scripts/openvpn-script --up-restart --setenv > CONNMAN_BUSNAME > :1.71 --setenv CONNMAN_INTERFACE net.connman.Task --setenv CONNMAN_PATH > > /task/0 --dev vpn0 --dev-type tun --persist-tun --route-noexec --ifconfig- > noexec --ping-restart 0 > > As it wasn't able to connect I've tried to run this command on my own: > > [root@localhost OpenVPN]# openvpn --remote olz.dyndns.org --ca > /home/nemo/OpenVPN/ca.crt --cert /home/nemo/OpenVPN/olz_mobile.crt --key > /home/nemo/OpenVPN/olz_mobile.key --comp-lzo --nobind --persist-key --client > --script-security 2 --up /usr/lib/connman/scripts/openvpn-script > --up-restart --setenv CONNMAN_BUSNAME :1.71 --setenv CONNMAN_INTERFACE > net.connman.Task -- setenv CONNMAN_PATH /task/0 --dev vpn0 --dev-type tun > --persist-tun --route- noexec --ifconfig-noexec --ping-restart 0 > Sun Jan 5 01:41:41 2014 OpenVPN 2.2.2 armv7l-unknown-linux-gnueabi [SSL] > [LZO2] [EPOLL] [PKCS11] [eurephia] built on Nov 1 2013 > Sun Jan 5 01:41:41 2014 WARNING: No server certificate verification method > has been enabled. See http://openvpn.net/howto.html#mitm for more info. > Sun Jan 5 01:41:41 2014 NOTE: the current --script-security setting may > allow this configuration to call user-defined scripts > Sun Jan 5 01:41:41 2014 LZO compression initialized > Sun Jan 5 01:41:42 2014 UDPv4 link local: [undef] > Sun Jan 5 01:41:42 2014 UDPv4 link remote: 188.194.98.162:1194 > Sun Jan 5 01:42:17 2014 [olz.dyndns.org] Peer Connection Initiated with > 188.194.98.162:1194 > Sun Jan 5 01:42:20 2014 TUN/TAP device vpn0 opened > Sun Jan 5 01:42:20 2014 /usr/lib/connman/scripts/openvpn-script vpn0 1500 > 1542 192.168.100.202 192.168.100.201 init > Sun Jan 5 01:42:20 2014 Initialization Sequence Completed > > The issue is related to the script: > > /usr/lib/connman/scripts/openvpn-script > > which just seems to do nothing. > > When I'm just removing the options: > > --route-noexec --ifconfig-noexec > > from the command above it is connecting fine: > > Sun Jan 5 01:57:32 2014 OpenVPN 2.2.2 armv7l-unknown-linux-gnueabi [SSL] > [LZO2] [EPOLL] [PKCS11] [eurephia] built on Nov 1 2013 > Sun Jan 5 01:57:32 2014 WARNING: No server certificate verification method > has been enabled. See http://openvpn.net/howto.html#mitm for more info. > Sun Jan 5 01:57:32 2014 NOTE: the current --script-security setting may > allow this configuration to call user-defined scripts > Sun Jan 5 01:57:32 2014 LZO compression initialized > Sun Jan 5 01:57:33 2014 UDPv4 link local: [undef] > Sun Jan 5 01:57:33 2014 UDPv4 link remote: 188.194.98.162:1194 > Sun Jan 5 01:58:07 2014 [olz.dyndns.org] Peer Connection Initiated with > 188.194.98.162:1194 > Sun Jan 5 01:58:10 2014 TUN/TAP device vpn0 opened > Sun Jan 5 01:58:10 2014 /sbin/ip link set dev vpn0 up mtu 1500 > Sun Jan 5 01:58:10 2014 /sbin/ip addr add dev vpn0 local 192.168.100.202 > peer 192.168.100.201 > Sun Jan 5 01:58:10 2014 /usr/lib/connman/scripts/openvpn-script vpn0 1500 > 1542 192.168.100.202 192.168.100.201 init > RTNETLINK answers: File exists > Sun Jan 5 01:58:10 2014 ERROR: Linux route add command failed: external > program exited with error status: 2 > Sun Jan 5 01:58:10 2014 Initialization Sequence Completed > > ifconfig: > > vpn0 Link encap:UNSPEC HWaddr > 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 > inet addr:192.168.100.202 P-t-P:192.168.100.201 > Mask:255.255.255.255 > UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1 > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 txqueuelen:100 > RX bytes:0 (0.0 b) TX bytes:0 (0.0 b) > > > Is this a bug inside connman or jolla? Could anyone help in finding a > solution? > > BR, > > Matthias > ___ > SailfishOS.org Devel mailing list Here is some log that is created: Jan 05 23:47:48 localhost openvpn[2854]: /usr/lib/connman/scripts/openvpn- script vpn0 1500 1542 192.168.100.202 192.168.100.201 init Jan 05 23:47:48 localhost connmand[794]: Adding host route failed (No such process) Jan 05 23:47:48 localhost connmand[794]: connman_inet_clear_ipv6_address: Invalid argument Jan 05 23:47:48 localhost connmand[794]: connman_inet_clear_ipv6_address: Invalid argument Jan 05 23:47:48 localhost connmand[794]: Skipping disconnect of /ril_0/context1, network is connecting. Jan 05 23:47:48 localhost connmand[794]: Failed to change property: /ril_
Re: [SailfishDevel] Is pragmatically taking a screenshot possible?
On Sunday 05 January 2014 13:42 James Mugford wrote: > Is it technically possible to create an app that can take a screenshot > of the home screen or device viewport? > > It is for the purpose of creating something technologically similar to a > water screen saver. I've no big knowledge of the subject, but I guess the easiest approach is to use dbus to grab the screenshot. >From the "grabscreen" script on the device, the cli command is something like: dbus-send --type=method_call --dest=org.nemomobile.lipstick \ /org/nemomobile/lipstick/screenshot org.nemomobile.lipstick.saveScreenshot string:"$filename" Where $filename is the file to save to. Maybe other methods than saveScreenshot is available? I have no idea how to query for available methods. -- Med venlig hilsen / Best Regards Thomas Tanghus ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] ContextMenu with repeater
I've noticed that if the model changes you can't depend on index except if you cache it, so something like this *should* work: onClicked: { var idx = index; console.log("selected: " + modelData) console.log("selected: " + idx) } On Friday 03 January 2014 21:21 Andrey Kozhevnikov wrote: > Hello > > I can't get context menu index if using repeater inside > > ComboBox { > id: languageCombo > label: "Language" > currentIndex: 0 > menu: ContextMenu { > id: languageMenu > Repeater { > width: parent.width > model: localeNames > delegate: MenuItem { > text: modelData > onClicked: { > console.log("selected: " + modelData) > console.log("selected: " + index) > } > } > } > onActiveChanged: { > console.log("index: " + languageCombo.currentIndex) > } > } > onCurrentIndexChanged: { > if (languageMenu.active) { > console.log(index: " + currentIndex) > } > } > } > > No output is produced when i selecting item, but item in repeater changed. > ___ > SailfishOS.org Devel mailing list -- Med venlig hilsen / Best Regards Thomas Tanghus ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Qt Creator Yaml file editor loses new entries
On Sunday 05 January 2014 14:12 Putze Sven wrote: > IMHO the .yaml file is (partly) rewritten if something changes in your .pro > file, Which is good to start with, but f* annoying in the long run, firstly because it's writing full paths as in /usr/share instead of %{_datadir} and insists in making those "corrections" every time you touch the .pro, secondly because it makes any kind of Continuous Integration close to impossible if you have the IDE open when it's is running. Causes a loop between SDK IDE noticing .pro has been **touched**, not edited, and then updating the .yaml, ending up in git conflicts. *Sigh* - I spend the better part of last night trying to figure out where my very simple scripts went wrong, until I found out it was the freaking SDK that was messing with me :D Sorry, kinda OT but otherwise SDK related ;) -- Med venlig hilsen / Best Regards Thomas Tanghus ___ SailfishOS.org Devel mailing list
[SailfishDevel] AAC support
Hi all, I've been testing a bit different music file/stream formats on the phone Everything seems fine for flac/ogg/mp3, however I got some problems with AAC format I've tried several AAC/AAC-HE samples: - some found on the Internet - some converted from my collection - some streaming links And some files are played correctly, some not... It seems like no .aac file can be played and only some .m4a (with AAC) can (but still not all) Launching a AAC stream with gstreamer from command line like gst-launch-0.10 -v playbin2 uri=http://sfstream1.somafm.com:3000 is telling me among other things Missing element: MPEG Audio decoder Can someone tell me what is going on? And what to do if possible (any extra plugin/package to install?...) Thanks a lot Damien ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] AAC support
On Monday 06 January 2014 00:46 Damien Tardy-Panis wrote: > Hi all, > > I've been testing a bit different music file/stream formats on the phone > Everything seems fine for flac/ogg/mp3, however I got some problems with AAC > format > > I've tried several AAC/AAC-HE samples: > - some found on the Internet > - some converted from my collection > - some streaming links > > And some files are played correctly, some not... > It seems like no .aac file can be played and only some .m4a (with AAC) can > (but still not all) > > Launching a AAC stream with gstreamer from command line like > gst-launch-0.10 -v playbin2 uri=http://sfstream1.somafm.com:3000 > is telling me among other things > Missing element: MPEG Audio decoder > > Can someone tell me what is going on? > And what to do if possible (any extra plugin/package to install?...) Missing codec? https://together.jolla.com/question/7364/crowdfunding-licensed-software-for-jolla-sailfishos/ mentions it. -- Med venlig hilsen / Best Regards Thomas Tanghus ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Cannot access phone book on phone when starting app from QtCreator
Hi Matze, I observed the same issue. I used QtContacts 5.0 in Qml and selected "org.nemomobile.contacts.sqlite" from the available managers for ContactModel.manager In the output from the application started with QtCreator I read the error message: Unable to create contacts database directory /home/nemo/.local/share/system//privileged/Contacts/qtcontacts-sqlite so there is a double-slash in the path. I already found at the source of qtcontacts-sqlite in file: https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/contactsdatabase.cpp and method: QSqlDatabase ContactsDatabase::open(const QString &databaseName) how the path is created: QString privilegedDataDir(QString("%1/%2/") .arg(QString::fromLatin1(QTCONTACTS_SQLITE_CENTRAL_DATA_DIR)) .arg(QString::fromLatin1(QTCONTACTS_SQLITE_PRIVILEGED_DIR))); I further found the defines in https://github.com/nemomobile/qtcontacts-sqlite/blob/master/src/engine/engine.pro where DEFINES += 'QTCONTACTS_SQLITE_CENTRAL_DATA_DIR=\'\"/home/nemo/.local/share/system/\"\'' already includes the slash. So at this point I know why the double slash is in the path. What I do not understand at all is: Why it works when I launch it at the phone? Best regards, Karsten Am Sonntag 05 Januar 2014, 23:10:46 schrieb Matthias Barmeier: >Hi, > >I am unable to access the phone book when running my app from QtCreator >on the phone. >Is this a security feature ? >Is it possible to work with a fake contact DB ? > >Ciao > Matze >___ >SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Is pragmatically taking a screenshot possible?
Great, this sounds hopeful. Do you know if there are there any permission issues surrounding this? For example, do you think this would work as a regular application on end consumer devices? Best On 05/01/14 23:21, Thomas Tanghus wrote: On Sunday 05 January 2014 13:42 James Mugford wrote: Is it technically possible to create an app that can take a screenshot of the home screen or device viewport? It is for the purpose of creating something technologically similar to a water screen saver. I've no big knowledge of the subject, but I guess the easiest approach is to use dbus to grab the screenshot. From the "grabscreen" script on the device, the cli command is something like: dbus-send --type=method_call --dest=org.nemomobile.lipstick \ /org/nemomobile/lipstick/screenshot org.nemomobile.lipstick.saveScreenshot string:"$filename" Where $filename is the file to save to. Maybe other methods than saveScreenshot is available? I have no idea how to query for available methods. ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Is pragmatically taking a screenshot possible?
It certainly does; there are 2 screenshot apps in the Harbour - check in 'utils' section David (Author of 'screenshot' ... with an update in QA right now) On 06/01/14 00:48, James Mugford wrote: > Great, this sounds hopeful. > > Do you know if there are there any permission issues surrounding this? > > For example, do you think this would work as a regular application on end > consumer devices? > > Best > > On 05/01/14 23:21, Thomas Tanghus wrote: >> On Sunday 05 January 2014 13:42 James Mugford wrote: >>> Is it technically possible to create an app that can take a screenshot >>> of the home screen or device viewport? >>> >>> It is for the purpose of creating something technologically similar to a >>> water screen saver. >> I've no big knowledge of the subject, but I guess the easiest approach is to >> use dbus to grab the screenshot. >> From the "grabscreen" script on the device, the cli command is something >> like: >> >> dbus-send --type=method_call --dest=org.nemomobile.lipstick \ >> /org/nemomobile/lipstick/screenshot >> org.nemomobile.lipstick.saveScreenshot string:"$filename" >> >> Where $filename is the file to save to. Maybe other methods than >> saveScreenshot >> is available? I have no idea how to query for available methods. >> > > ___ > SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Undocumented Silica components
Hi, As a general rule, if it’s not documented then it isn’t public API. The GlassItem API hasn’t been reviewed for public use. It will probably change and is not safe for use. The busy property of PullDownMenu is documented, but the docs have not been updated in the SDK. OpacityRampEffect has been reviewed for public use, but is not yet documented. We’ll do this asap. Best Regards, Martin. On 3 Jan 2014, at 6:58 am, Luciano Montanaro wrote: > I don't know if this has been addresed already, but... > > In my application, I would like to use a few components that the > componentgallery is demoing, but that are not documented in the > reference documentation. > Is it OK to use everything that works there? > > Specifically, I want to use > > * OpacityRampEffect for my coverpage > * the busy property of the PullDownMenu while fetching status updates > * possibly the GlassItem as an indicator of the train delay > > Since I would like for my application to eventually be distributed > through the Harbour, I would like to know if it is OK to do so. > > Best regards, > Luciano > > -- > Luciano Montanaro > > Anyone who is capable of getting themselves made President should on > no account be allowed to do the job. -- Douglas Adams > ___ > SailfishOS.org Devel mailing list ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Is pragmatically taking a screenshot possible?
On Monday 06 January 2014 00:48 James Mugford wrote: > Great, this sounds hopeful. > > Do you know if there are there any permission issues surrounding this? I doubt so. As mentioned in https://together.jolla.com/question/9670/api-security-model/ the current security model is QA, Unix permissions and general rep ;) And you can do it as user nemo so it *should* work. > For example, do you think this would work as a regular application on > end consumer devices? I can't give a qualified answer to that, sorry. > On 05/01/14 23:21, Thomas Tanghus wrote: > > On Sunday 05 January 2014 13:42 James Mugford wrote: > >> Is it technically possible to create an app that can take a screenshot > >> of the home screen or device viewport? > >> > >> It is for the purpose of creating something technologically similar to a > >> water screen saver. > > > > I've no big knowledge of the subject, but I guess the easiest approach is > > to use dbus to grab the screenshot. > > > > From the "grabscreen" script on the device, the cli command is something > > like: > > dbus-send --type=method_call --dest=org.nemomobile.lipstick \ > > > > /org/nemomobile/lipstick/screenshot > > org.nemomobile.lipstick.saveScreenshot string:"$filename"> > > Where $filename is the file to save to. Maybe other methods than > > saveScreenshot is available? I have no idea how to query for available -- Med venlig hilsen / Best Regards Thomas Tanghus ___ SailfishOS.org Devel mailing list
Re: [SailfishDevel] Is pragmatically taking a screenshot possible?
Hi James, you can also look at source code of my screenshot taking app: https://github.com/fk-lx/SailshotMe Regards, Filip ___ SailfishOS.org Devel mailing list