Re: Building for Android and F-Droid

2016-09-11 Thread Andreas Enge
Hello,

if I remember correctly, the last time I tried I could not use our icedtea
package to build android apps, so I gave up looking into anything android
like for guix. Did this work for you?

Andreas




Re: Building for Android and F-Droid

2016-09-05 Thread Hartmut Goebel
Am 05.09.2016 um 11:35 schrieb Efraim Flashner:
> Of course currently building apks
> doesn't work, and I haven't really tested much of the functionality yet.

Well, building apks actually works :-) (I have not tested your code,
though).

fdroid is building it's own build-server VM (this is what
fdroidbuildserver does). And the apks are build in there. For actually
building an apk you'll need the fdroiddata package (which to have
package for guix is quite useless IMHO). See the manual at
 and my updates to the manual
.

So the vision I expressed in my first posting on this thread is: Change
the fdroid-server to use GuixSD (in a container?) instead of a VM :-)

-- 
Schönen Gruß
Hartmut Goebel
Dipl.-Informatiker (univ), CISSP, CSSLP, ISO 27001 Lead Implementer
Information Security Management, Security Governance, Secure Software
Development

Goebel Consult, Landshut
http://www.goebel-consult.de

Blog:
http://www.goebel-consult.de/blog/filmgesprach-zu-201ecitizenfour201c-in-herrsching

Kolumne: http://www.cissp-gefluester.de/2010-01-hinterturen-allen-ortes



signature.asc
Description: OpenPGP digital signature


Re: Building for Android and F-Droid

2016-09-05 Thread Efraim Flashner
On Thu, Sep 01, 2016 at 03:57:13PM +0200, Ricardo Wurmus wrote:
> 
> Thompson, David  writes:
> 
> > Does anyone know what we are missing to be able to package android
> > tools?
> 
> Given the current state of our support for Java I’d say we mostly need
> more Java packages in Guix.  A first big step would be to package enough
> to be able to build Maven from source (no cheating).
> 
> ~~ Ricardo
> 
> 

If anyone wants to play around with f-droid, I have it packaged in my
GUIX_PACKAGE_PATH, waiting to be tested more before breaking it down
into patches and submitting it. Of course currently building apks
doesn't work, and I haven't really tested much of the functionality yet.

-- 
Efraim Flashner  אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
;;; Copyright © 2016 Efraim Flashner 
;;;
;;; This file is an addendum to GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see .

(define-module (wip fdroid)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (guix download)
  #:use-module (guix packages)
  #:use-module (guix build-system python)
  #:use-module (gnu packages python))

(define-public fdroidserver
  (package
(name "fdroidserver")
(version "0.6.0")
(source
  (origin
(method url-fetch)
(uri (pypi-uri "fdroidserver" version))
(sha256
 (base32
  "1fi4kkgi59gd9nssy9zc86b8rki3m47pd29vc821jgsa89lgjqf5"
(build-system python-build-system)
(arguments
 `(#:phases
   (modify-phases %standard-phases
 ;; this prevents the examples from being installed
 ;; we want to fix this later
 (add-before 'install 'patch-install-locations
   (lambda _
 (substitute* "setup.py"
  (("\\(data_prefix\\ \\+\\ 
'/share/doc/fdroidserver/examples',") "")
  (("\\['buildserver") "'buildserver")
  (("'\\]\\)") "'")
  )
 #t)))
   #:python ,python-2)) ; after 0.6.0 it switches to python3
(inputs
 `(("python2-apache-libcloud" ,python2-apache-libcloud)
   ("python2-mwclient" ,python2-mwclient)
   ("python2-paramiko" ,python2-paramiko)
   ("python2-pillow" ,python2-pillow)
   ("python2-pyasn1" ,python2-pyasn1)
   ("python2-pyasn1-modules" ,python2-pyasn1-modules)
   ("python2-pyyaml" ,python2-pyyaml)
   ("python2-requests" ,python2-requests)))
(propagated-inputs
 `(("python2-crypto" ,python2-crypto))) ; not sure this is the right one
(home-page "https://f-droid.org";)
(synopsis "F-Droid Server Tools")
(description "F-Droid Server Tools")
(license license:agpl3+)))

(define-public python-mwclient
  (package
 (name "python-mwclient")
 (version "0.8.1")
 (source
   (origin
 (method url-fetch)
 (uri (pypi-uri "mwclient" version))
 (sha256
  (base32
   "1r322v6i6xps9xh861rbr4ggshydcgp8cycbdlmgy8qbrh8jg2az"
(build-system python-build-system)
(arguments
 `(#:phases
   (modify-phases %standard-phases
 (replace 'check
   (lambda _
 (zero? (system* "py.test")))
(native-inputs
 `(("python-pytest-cache" ,python-pytest-cache)
   ("python-pytest-cov" ,python-pytest-cov)
   ("python-pytest-pep8" ,python-pytest-pep8)))
(inputs
 `(("python-funcsigs" ,python-funcsigs)
   ("python-mock" ,python-mock)
   ("python-requests" ,python-requests)
   ("python-responses" ,python-responses)
   ("python-six" ,python-six)))
(home-page "https://github.com/mwclient/mwclient";)
(synopsis "MediaWiki API client")
(description "MediaWiki API client")
(license license:expat)
(properties `((python2-variant . ,(delay python2-mwclient))

(define-public python2-mwclient
  (let ((base (package-with-python2
(strip-python2-variant python-mwclient
(package (inherit base)
  (native-inputs
   `(("python2-setuptools" ,python2-setuptools)
 ,@(package-native-inputs base))

(define-public python-funcsigs
  (package
(name "python-funcsigs")
(version "1.0.2")
(source
  (origin
(method url-fetch)
(uri (pypi-uri "funcsigs" version))
(sha256

Re: Building for Android and F-Droid

2016-09-01 Thread Ricardo Wurmus

Thompson, David  writes:

> Does anyone know what we are missing to be able to package android
> tools?

Given the current state of our support for Java I’d say we mostly need
more Java packages in Guix.  A first big step would be to package enough
to be able to build Maven from source (no cheating).

~~ Ricardo




Re: Building for Android and F-Droid

2016-09-01 Thread Thompson, David
On Thu, Sep 1, 2016 at 7:33 AM, Hartmut Goebel
 wrote:
> Hello,
>
> I just want to share an idea I had:
>
> Recently I was involved in packaging a app for f-droid. The f-droid build
> system consists of 1) a virtual machine which get cleaned up after each
> build. and 2) meta-data descriptions of each package. The meta-data includes
> build instructions and is basically a ini-like file. For a simple examples
> see [1] and for a complex one see [2].
>
> One of f-droid's goals is reproducible build. De-facto they fail on this,
> given the current set up since they update the virtual machine to some
> current state.
>
> In got the idea to make f-droid use guix as a base. Of course, this would be
> a lot of work, and I do not expect this to happen any time soon. We have
> quite a lot of work to do on the guix-side, like building the Android tools,
> implement maven and graddle builds, etc.

You are indeed correct that it would be a lot of work, but it is
certainly possible and sounds like it would be a big improvement over
the status quo.  I would also like to see this happen because I am an
F-Droid user.

Does anyone know what we are missing to be able to package android
tools?  I would like to be able to use the android debug bridge again
to shell into my phone. :)

- Dave



Building for Android and F-Droid

2016-09-01 Thread Hartmut Goebel
Hello,

I just want to share an idea I had:

Recently I was involved in packaging a app for f-droid. The f-droid
build system consists of 1) a virtual machine which get cleaned up after
each build. and 2) meta-data descriptions of each package. The meta-data
includes build instructions and is basically a ini-like file. For a
simple examples see [1] and for a complex one see [2].

One of f-droid's goals is reproducible build. De-facto they fail on
this, given the current set up since they update the virtual machine to
some current state.

In got the idea to make f-droid use guix as a base. Of course, this
would be a lot of work, and I do not expect this to happen any time
soon. We have quite a lot of work to do on the guix-side, like building
the Android tools, implement maven and graddle builds, etc.

As said: just wanted to share this idea,

[1]
https://gitlab.com/fdroid/fdroiddata/blob/master/metadata/com.colinmcdonough.android.torch.txt
[2]
https://gitlab.com/fdroid/fdroiddata/blob/master/metadata/pep.android.k9.txt

-- 
Schönen Gruß
Hartmut Goebel
Dipl.-Informatiker (univ), CISSP, CSSLP, ISO 27001 Lead Implementer
Information Security Management, Security Governance, Secure Software
Development

Goebel Consult, Landshut
http://www.goebel-consult.de

Blog:
http://www.goebel-consult.de/blog/digitale-burgerrechte-in-der-ara-snowden
Kolumne:
http://www.cissp-gefluester.de/2011-08-horrorszenario-bring-your-own-device



smime.p7s
Description: S/MIME Cryptographic Signature