Open mattab opened 10 years ago
Piwik Mobile lead Thomas wrote few weeks ago:
someone already tried to publish it there but was not really possible as the apps are built on F-droid and we are using a special technology to write our native Android app. We are using a framework named "Titanium Mobile" which allows us to write native apps with JavaScript. The people had no luck so far to get it working on F-droid but I think they are maybe still trying.
If anyone would like to try and publish Piwik Mobile in F-Droid please let us know! we would be happy to help and assist.
Another feedback
I would really love to use your app but I don't run proprietary Google Apps on my phone. I would recommend you to add your Piwik Android app to the F-Droid repository - https://f-droid.org/ as it serves as an FOSS app store where it would suit very well.
The Piwik-solution is already the official recommendation by F-Droid for Analytics-libraries in Apps. https://f-droid.org/wiki/page/FAQ_-_App_Developers#Which_free_library_should_I_use_.28instead_of_XXX.jar.29_to_implement_YYY
From Thomas:
The problem is that the app requires the Titanium Mobile SDK as the app is written in JavaScript. This requires for instances an account at Appcelerator to download, install and configure the SDK. Building Titanium Mobile from source can be quite complex as well, haven't done it yet. It also requires many node.js packages etc. The required version of Titanium Mobile SDK and the node packages change with every release but have to be exactly consistent with the ones we used during testing. Otherwise it is very likely the app would not work. Especially when building Titanium Mobile from source it is hard to guarantee the app would work and would most likely end in hours of testing for every release. I think someone has already tried to set it up but failed at this step.
Closing this issue as I won't make the app available in the FOSS app store re the mentioned reasons
:-1: i hope this will be a relevant task in the future again. as piwik advertises as the free tracking platform its a shame that they are not able to provide their app on the app store for free and open source software due depending on non-free libs and dependencies.
I will reopen this issue just in case anyone wants to work on this issue. Piwik Mobile itself is free and it is built on top of open source technologies and it is most likely possible to get it into F-Droid. I just won't have the time to work on this myself. An alternative to Google Play is always to download the APK from our site.
@stefan-niedermann If you know a free framework that allows us to develop easily native cross mobile apps with PHP or JavaScript AND provides good usability and performance for the user please let me know. I don't know any and PhoneGap/Cordova is not a solution as the performance/usability etc is not good and doesn't provide native components / speed. If you don't want to use the mobile app you can just open the regular Piwik in the browser itself. We'd be glad about contributions that make the regular Piwik more mobile friendly. Piwik is a platform developed by the community and depends on contributions.
This is also in the submission queue at F-Droid.org: https://f-droid.org/forums/topic/piwik-mobile-2-2/#post-16831
I've added a link there to this bug report.
I'm not sure if this has been talked about somewhere else, but you guys could host your own F-Droid repo. I see you are already hosting your own binaries on piwik.org. If you hosted your own f-droid repository and just threw the files on there, users could add the piwik repo on their client. That way they'd get updates pushed to their f-droid without having to manually check your website periodically. It would be your build instead of F-droid's, but that's what seems to be the big hiccup currently.
Here is the Guardian Project's self-hosted repository as an example. It doesn't seem like that much overhead, but that's up to you guys of course. Either way, it would be nice to have some update mechanism without needing Google Play Services.
Thanks for letting us know that this is possible. However, we likely won't have the time to do this soon
From Thomas:
The problem is that the app requires the Titanium Mobile SDK as the app is written in JavaScript. This requires for instances an account at Appcelerator to download, install and configure the SDK. Building Titanium Mobile from source can be quite complex as well, haven't done it yet. It also requires many node.js packages etc. The required version of Titanium Mobile SDK and the node packages change with every release but have to be exactly consistent with the ones we used during testing. Otherwise it is very likely the app would not work. Especially when building Titanium Mobile from source it is hard to guarantee the app would work and would most likely end in hours of testing for every release. I think someone has already tried to set it up but failed at this step.
I have no idea how the F-Drpod process is to build apps but why the piwik developers "just" provide their detailed "cookboo for building Piwik for Androik" to F-Droid?
I have no idea how the F-Drpod process is to build apps but why the piwik developers "just" provide their detailed "cookboo for building Piwik for Androik" to F-Droid?
that's not trivial though @saljut7 . If someone wants to help with this project and manages to build the Piwik Mobile app, we would welcome help!
I'm not sure if this has been talked about somewhere else, but you guys could host your own F-Droid repo. I see you are already hosting your own binaries on piwik.org. If you hosted your own f-droid repository and just threw the files on there, users could add the piwik repo on their client. That way they'd get updates pushed to their f-droid without having to manually check your website periodically. It would be your build instead of F-droid's, but that's what seems to be the big hiccup currently.
@jalami that's a very interesting idea. If someone wanted to set this up for the Piwik project we would support you, but unfortunately we don't have time to create this f droid repo project or maintain it.
@tsteur, @mattab, @jalami I finaly made the switch and removed all google play services from my phone and am only using fdroid anymore, so I'd be really interested in solving this.
As mentioned by thomas, getting the app into the official fdroid repo doesn't seem feasable because of the huge difference to a normal build.
But setting up a custom fdroid repo seems really easy and as thomas is aready publishing the APKs here, shouldn't be much extra work.
I'll try to setup a test repo and will report back.
Can we have a rough estimation of the time needed to cleanup, sanitize and publish the build toolchain environment, requirements and steps? Then I'd suggest exploring options to crowdfund it or straight pay for this time. @mattab could Innocraft take money to do this under a commercial contract?
I for one would fund part of it and given the huge Piwik community, am convinced it could be invited to contribute financially to the benefit of all interested parties. Charging for the iTunes/Google Play versions would also provide ongoing funding and be coherent with such distribution channels.
There was a release as recent as January 2018, I can't believe this is always done from scratch on some legacy environment that can't be rebuilt again independently.
@Findus23 this issue was about getting the GPLv3 app into F-Droid, not just about setting up a repository to make it upgradable in a convenient way. An important part of this is ensuring it can be built and there is good recipe for this, specially knowing the SDK used is also under a free software licence (APLv2). All libraries, art and resources used to build also have to be under compatible licenses, asking F-Droid again on their new forums would be best as the original thread I posted is since gone.
In this context setting up a repo just to distribute the binaries defeats the purpose of having vetted, independently-built, free software apps in F-Droid. The "big hiccup" is not only automatic upgrades.
@mattab had commented:
The problem is that the app requires the Titanium Mobile SDK as the app is written in JavaScript. This requires for instances an account at Appcelerator to download, install and configure the SDK. Building Titanium Mobile from source can be quite complex as well, haven't done it yet. It also requires many node.js packages etc. The required version of Titanium Mobile SDK and the node packages change with every release but have to be exactly consistent with the ones we used during testing. Otherwise it is very likely the app would not work.
I see the SDK can be downloaded directly now. I presume Innocraft was using the certified versions. The build toolchain would have to be testes again uncertified builds, and the build environment would need to be documented (Debian/Ubuntu VM needed? What packages are required? Steps? etc.).
@ghost asked
why [don't] the piwik developers "just" provide their detailed "cookbook for building Piwik for Android" to F-Droid?
The build process is probably not documented in a way that can be at least initially shared and then improved on by the community and was probably never planned to be published. The end result is the build toolchain appears to be some secret sauce and the community is expected to reverse-engineer it. I understand the resource limits and @tsteur and others have made it clear Innocraft is not against this, but it's not making it easy either.
I remain convinced this could be funded by the community and both Innocraft and all Matomo users would benefit in ways that remain consistent with core Matomo values.
The fdroidserver
package is really user-friendly.
I set up a test repository at
https://matomo-fdroid.lw1.at/fdroid/repo?fingerprint=E17D3E831EBFFBF60831FCA36A615769B31E3D1168A173F3CD9EA2FC29DF74D2
(an archive repo with older versions also exists)
So as long as @tsteur can create signed APKs, maintaining the fdroid repo is just copying into the correct folder, running fdroidserver
and rsync to the webserver.
Of course having an easier way to build the app oneself as @MagicFab suggests, is definitely worth achieving.
First steps to building:
yarn global add titanium alloy tisdk # or use npm
tisdk install 7.0.2.GA # install the same version as in the repo
ti build # select Android
In theory that's it. I also had to run
ti config android.buildTools.selectedVersion 27.0.3 # because my version is too new
echo "{}" > ~/.titanium/config.json
Unfortunately titanium isn't compatible with OpenJDK, so I don't get any further.
Would you need to build Titanium SDK etc from source as well? Not sure if much has changed in recent years and whether it is easier to build Android APK through command line or not and which node.js versions are compatible etc. With every release the Titanium CLI, SDK, ... etc version changes so whatever APK is being built through this would need to be tested separately to make sure everything works.
@tsteur Guess taking the opensource titanium build is okay, but I tried yesterday to write a complete build script failed as
Using the specific version of titanium every time is less of an issue as you can specify it.
F-Droid is an installable catalogue of FOSS (Free and Open Source Software) applications for the Android platform.
We have been asked several times about publishing Piwik Mobile (full GPLv3 license) in f-droid. This ticket is about to discuss or see, if and how it could be done at some point.
Learn more about F-Droid: Interview with Ciaran Gultnieks of F-Droid