[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Come back and graphical installer
From: |
Danny Milosavljevic |
Subject: |
Re: Come back and graphical installer |
Date: |
Mon, 22 Oct 2018 15:58:47 +0200 |
Hi,
On Sat, 20 Oct 2018 21:48:34 +0600
Mathieu Othacehe <address@hidden> wrote:
> * Using Anaconda[1] as suggested by Harmut would mean interfacing a huge
> codebase in Python, written for FHS based distributions.
I just want to throw this over the fence... *runs away*:
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2018 Danny Milosavljevic <address@hidden>
;;;
;;; This file is part of 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 <http://www.gnu.org/licenses/>.
(define-module (wip anaconda)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix utils)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module (guix build-system gnu)
#:use-module (guix build-system python)
#:use-module (gnu packages)
#:use-module (gnu packages admin)
#:use-module (gnu packages autotools)
#:use-module (gnu packages backup)
#:use-module (gnu packages base)
#:use-module (gnu packages check)
#:use-module (gnu packages curl)
#:use-module (gnu packages databases)
#:use-module (gnu packages disk)
#:use-module (gnu packages flex)
#:use-module (gnu packages gettext)
#:use-module (gnu packages glib)
#:use-module (gnu packages gnome)
#:use-module (gnu packages gnuzilla)
#:use-module (gnu packages gtk)
#:use-module (gnu packages linux)
#:use-module (gnu packages nettle)
#:use-module (gnu packages networking)
#:use-module (gnu packages time)
#:use-module (gnu packages package-management)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages popt)
#:use-module (gnu packages python)
#:use-module (gnu packages python-web)
#:use-module (gnu packages selinux)
#:use-module (gnu packages textutils)
#:use-module (gnu packages tls)
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg))
(define-public python-blivet
(package
(name "python-blivet")
(version "0.61.15")
(source (origin
(method url-fetch)
(uri
(string-append
"https://github.com/storaged-project/blivet/archive/blivet-"
version ".tar.gz"))
(sha256
(base32
"0j01wjb2drz1r9f4006xn0g9r7hiqm679diczi4z7hsh850v85f7"))))
(build-system python-build-system)
(home-page "https://fedoraproject.org/wiki/Blivet")
(synopsis "Installer")
(description "Installer.")
(license license:gpl2))) ; FIXME
(define-public python2-blivet
(package-with-python2 python-blivet))
(define-public python-ordered-set
(package
(name "python-ordered-set")
(version "2.0.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "ordered-set" version))
(sha256
(base32
"1swh7b75qz9d2179z36ll4n41vf2b8wgngg9rgan01svgmfssb4l"))))
(build-system python-build-system)
(native-inputs
`(("python-nose" ,python-nose)))
(home-page "http://github.com/LuminosoInsight/ordered-set")
(synopsis "MutableSet that remembers its order in Python")
(description
"A MutableSet that remembers its order, so that every entry has an index.")
(license #f)))
(define-public python2-ordered-set
(package-with-python2 python-ordered-set))
(define-public python-pykickstart
(package
(name "python-pykickstart")
(version "3.7")
(source
(origin
(method url-fetch)
(uri (pypi-uri "pykickstart" version))
(sha256
(base32
"09fp4n8sz8xvcljhhs09w9m1gca0bbcxbcmyd0bdc9xxp0sy4576"))))
(build-system python-build-system)
(propagated-inputs
`(("python-ordered-set" ,python-ordered-set)))
(home-page
"http://fedoraproject.org/wiki/pykickstart")
(synopsis
"Python module for manipulating kickstart files")
(description
"Python module for manipulating kickstart files")
(license #f))) ; FIXME
(define-public python2-pykickstart
(package-with-python2 python-pykickstart))
(define-public python-langtable
(package
(name "python-langtable")
(version "0.0.38")
(source (origin
(method url-fetch)
(uri
(string-append
"https://github.com/mike-fabian/langtable/archive/" version ".tar.gz"))
(sha256
(base32
"00634x2hjrvf45a3wsjb38cni7rc2bdb39a86rvzyz8syv9igxy1"))))
(build-system python-build-system)
(home-page "https://fedoraproject.org/wiki/Anaconda")
(synopsis "Langtable")
(description "Langtable.")
(license license:gpl3+))) ; FIXME and MIT
(define-public python2-langtable
(package-with-python2 python-langtable))
;; FIXME make an independent package.
(define-public python2-selinux
(package (inherit libselinux)
(name "python2-selinux")
(native-inputs
(cons* `("flex" ,flex) `("python-2" ,python-2)
(package-native-inputs libselinux)))
(inputs
`())
(arguments
(substitute-keyword-arguments (package-arguments libselinux)
((#:make-flags flags)
`(cons* "PYTHON=python2"
(string-append "LIBSEPOLA="
(assoc-ref %build-inputs "libsepol")
"/lib/libsepol.a")
(string-append "PYSITEDIR="
(assoc-ref %outputs "out")
"/lib/python"
,(version-major+minor (package-version python-2))
"/site-packages/")
(let ((out (assoc-ref %outputs "out")))
(list (string-append "PREFIX=" out)
(string-append "DESTDIR=" out)
(string-append "MAN3DIR=" out "/share/man/man3")
(string-append "MAN5DIR=" out "/share/man/man5")
(string-append "MAN8DIR=" out "/share/man/man8")
(string-append "LDFLAGS=-Wl,-rpath=" out "/lib")
"CC=gcc"))
))))))
(define-public python-ntplib
(package
(name "python-ntplib")
(version "0.3.3")
(source
(origin
(method url-fetch)
(uri (pypi-uri "ntplib" version))
(sha256
(base32
"1piy4x71lp6ra8vligcbh6zzn1mgnjh1p9yrkcflds8bsmj1nqn4"))))
(build-system python-build-system)
(home-page "http://code.google.com/p/ntplib/")
(synopsis "NTP client library for Python")
(description "This package provides an Network Time Protocol client.")
(license license:expat)))
(define-public python2-ntplib
(package-with-python2 python-ntplib))
(define-public python-urlgrabber
(package
(name "python-urlgrabber")
(version "3.10.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "urlgrabber" version))
(sha256
(base32
"0w1h7hlsq406bxfy2pn4i9bd003bwl0q9b7p03z3g6yl0d21ddq5"))))
(build-system python-build-system)
(propagated-inputs
`(("python2-pycurl" ,python2-pycurl)))
(home-page "http://urlgrabber.baseurl.org/")
(synopsis
"A high-level cross-protocol url-grabber")
(description
"A high-level cross-protocol url-grabber")
(license #f)))
(define-public python2-urlgrabber
(package-with-python2 python-urlgrabber))
(define-public python-meh
(package
(name "python-meh")
(version "1.2.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "Meh" version))
(sha256
(base32
"0hwg3vqpiqb80ff7is3v202cz98b764nizlizpq9h2m2xn99vpf1"))))
(build-system python-build-system)
(arguments
`(#:tests? #f))
(home-page
"https://github.com/PhilipTrauner/Meh")
(synopsis
"Python configuration files in Python.")
(description
"Python configuration files in Python.")
(license #f)))
(define-public python2-meh
(package-with-python2 python-meh))
(define-public python-rpmfluff
(package
(name "python-rpmfluff")
(version "0.5.4")
(source
(origin
(method url-fetch)
(uri (string-append "https://releases.pagure.org/rpmfluff/rpmfluff-"
version ".tar.xz"))
(sha256
(base32
"16q38v575yn3m8nf417sfhnhfj856c1wxghhngkzlbcjqkv1lj90"))))
(build-system python-build-system)
(arguments
`(#:tests? #f))
(home-page
"https://github.com/PhilipTrauner/Meh")
(synopsis
"Python configuration files in Python.")
(description
"Python configuration files in Python.")
(license #f)))
(define-public python2-rpmfluff
(package-with-python2 python-rpmfluff))
(define-public anaconda
(package
(name "anaconda")
(version "21.48.22.133-1")
(source (origin
(method url-fetch)
(uri
(string-append "https://github.com/rhinstaller/anaconda/archive/"
name "-" version ".tar.gz"))
(sha256
(base32
"186sp1j9n31r147nh2b5iv5sj22qmxbaz3p2lmsllanp42129akd"))))
(build-system gnu-build-system)
(arguments
`(#:make-flags '("V=1")
#:phases
(modify-phases %standard-phases
(add-before 'bootstrap 'patch-bootstrapper
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "widgets/autogen.sh"
(("/bin/bash") (which "bash"))
(("/usr/share/gettext")
(string-append (assoc-ref inputs "gettext") "/share/gettext")))
#t))
(add-after 'unpack 'patch-out-rpm
(lambda _
(substitute* "tests/glade/run_glade_tests.sh"
((" rpm -q ") " true "))
#t))
(add-after 'configure 'configure-widgets
(lambda* (#:key outputs #:allow-other-keys)
(chdir "widgets")
(setenv "CONFIG_SHELL" (which "sh"))
(invoke (which "sh") "./configure" (string-append "CONFIG_SHELL="
(which "sh"))
(string-append "--prefix=" (assoc-ref outputs "out")))
(chdir "..")
#t))
(add-after 'configure-widgets 'msginit
(lambda* (#:key inputs #:allow-other-keys)
(define (filter-environment! filter-predicate
environment-variable-names)
(for-each
(lambda (env-name)
(let* ((env-value (getenv env-name))
(search-path (search-path-as-string->list env-value))
(new-search-path (filter filter-predicate
search-path))
(new-env-value (list->search-path-as-string
new-search-path ":")))
(setenv env-name new-env-value)))
environment-variable-names))
(substitute* "utils/dd/Makefile"
;(("LDFLAGS =") (string-append "LDFLAGS=-Wl,-rpath=" (assoc-ref
inputs "nss") "/lib/nss"))
;; It's using $(LDFLAGS) before setting LDFLAGS.
(("[$][(]LDFLAGS[)]") (string-append "-R " (assoc-ref inputs
"nss") "/lib/nss"
" -L" (assoc-ref inputs
"nss") "/lib/nss")))
(substitute* "tests/pylint/runpylint.sh"
((" /bin/sh ") " sh "))
(substitute* "tests/pyanaconda_tests/iutil_test.py"
(("\"/bin/sh\"") "\"sh\"")
(("\"/bin/true\"") "\"true\"")
(("\"/bin/echo\"") "\"echo\""))
;; Someone injects enum34 - and that's incompatible with Python3.6.
(filter-environment! (lambda (name) (not (string-contains name
"enum34"))) '("PYTHONPATH"))
;; FIXME: hardcode it in pyanaconda somehow.
(setenv "TZDIR"
(string-append (assoc-ref inputs "tzdata")
"/share/zoneinfo"))
(chdir "po")
;; FIXME: Fetch those files.
(for-each
(lambda (x)
(invoke "msginit" "--no-translator" "-o" x))
'("af.po" "am.po" "ar.po" "as.po" "ast.po" "be.po" "bg.po"
"bn.po" "bn_IN.po" "bs.po" "ca.po" "cs.po" "cy.po" "da.po" "de.po" "de_CH.po"
"el.po" "en_GB.po" "es.po" "et.po" "eu.po" "fa.po" "fi.po" "fr.po" "gl.po"
"gu.po" "hi.po" "hr.po" "hu.po" "ia.po" "id.po" "ilo.po" "is.po" "it.po"
"ja.po" "ka.po" "kk.po" "kn.po" "ko.po" "lt.po" "lv.po" "ne.po" "nl.po"
"nso.po" "or.po" "pa.po" "pl.po" "pt.po" "pt_BR.po" "ro.po" "ru.po" "si.po"
"sk.po" "sl.po" "sq.po" "sr.po" "address@hidden" "sv.po" "ta.po" "te.po"
"tg.po" "th.po" "tr.po" "uk.po" "ur.po" "vi.po" "zh_CN.po" "zh_TW.po" "zu.po"
"mai.po" "mk.po" "mr.po" "ml.po" "mr.po" "ms.po" "nb.po"))
(chdir "..")
#t))
(add-before 'check 'set-typelib-path
(lambda* (#:key inputs #:allow-other-keys)
(setenv "GI_TYPELIB_PATH" (string-append (assoc-ref inputs
"gtk+") "/share/gir-1.0:"
(string-append (assoc-ref inputs
"network-manager") "/share/gir-1.0")))
#t))
(add-after 'install 'install-widgets
(lambda _
#t)))))
(inputs
`(("audit" ,audit)
("bdb" ,bdb)
("gettext" ,gettext-minimal) ; widgets
("glade3" ,glade3) ; widgets
("glib" ,glib)
("gtk+" ,gtk+) ; widgets
("gobject-introspection" ,gobject-introspection)
("libarchive" ,libarchive)
("libx11" ,libx11)
("libxklavier" ,libxklavier)
("libxml2" ,libxml2)
("nettle" ,nettle)
("network-manager" ,network-manager)
("nss" ,nss)
("popt" ,popt)
("python-2" ,python-2)
("tzdata" ,tzdata)
("rpm" ,rpm)))
(propagated-inputs
`(("python2-blivet" ,python2-blivet)
("python2-dbus" ,python2-dbus)
("python2-ipy" ,python2-ipy)
("python2-urlgrabber" ,python2-urlgrabber)
("python2-ntplib" ,python2-ntplib)
("python2-parted" ,python2-parted)
("python2-pytz" ,python2-pytz)
("python2-requests" ,python2-requests)
("python2-meh" ,python2-meh)
("libostree" ,libostree)
("python2-pygobject" ,python2-pygobject))) ; FIXME regular inputs.
(native-inputs
`(("autoconf" ,autoconf)
("automake" ,automake)
("gettext" ,gettext-minimal)
("glib-bin" ,glib "bin")
("gnome-icon-theme" ,gnome-icon-theme)
("gtk-doc" ,gtk-doc)
("intltool" ,intltool)
("libtool" ,libtool)
("pkg-config" ,pkg-config)
("python-2" ,python-2)
("python2-lxml" ,python2-lxml)
("python2-pylint" ,python2-pylint)
("python2-polib" ,python2-polib)
("python2-nose" ,python2-nose)
("python2-mock" ,python2-mock)
("python2-pykickstart" ,python2-pykickstart)
("python2-selinux" ,python2-selinux)
("python2-langtable" ,python2-langtable)
("python2-rpmfluff" ,python2-rpmfluff)
; FIXME add gi.repository: NetworkManager Gtk Gdk TimezoneMap Pango
NMClient GdkPixbuf Keybinder AnacondaWidgets GdkX11 Xkl NM
("cppcheck" ,cppcheck)))
(home-page "https://fedoraproject.org/wiki/Anaconda")
(synopsis "Installer")
(description "Installer.")
(license license:gpl2)))
; libuser blivet.util pwquality[runpath problems]
pgpbu9kT_oXVh.pgp
Description: OpenPGP digital signature