summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2019-10-25 09:05:28 +0200
committerRicardo Wurmus <rekado@elephly.net>2019-10-25 09:05:28 +0200
commit98fbbbd08de396cd8a0e45f2a4badf1c733a5772 (patch)
tree84a168fc3770f571202e72e70584de9c03c023b9
parent0e6e09d09f42fe88a7163b47d2e7dcd0d789f37f (diff)
Use Makefile.
-rw-r--r--Makefile17
-rw-r--r--README.org8
-rw-r--r--guix/rekado/guile-studio.scm43
3 files changed, 40 insertions, 28 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..34ae7a6
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,17 @@
+VERSION = 0.0.1
+
+SOURCES = \
+ guile-studio-configure.scm \
+ logo.svg \
+ Makefile \
+ README.org
+
+build:
+ mkdir -p $(PREFIX)/bin && \
+ mkdir -p $(PREFIX)/share && \
+ guile -s guile-studio-configure.scm \
+ $(PREFIX) $(EMACS_DIR) $(GUILE_DIR) $(PICT_DIR) $(ICONS_DIR) $(INPUTS)
+
+dist:
+ mkdir -p guile-studio && cp $(SOURCES) guile-studio && \
+ tar -czf guile-studio-$(VERSION).tar.gz guile-studio
diff --git a/README.org b/README.org
index 371ae38..3dde643 100644
--- a/README.org
+++ b/README.org
@@ -13,6 +13,8 @@ pleasant Guile + Geiser experience out of the box.
To build Guile Studio from source with Guix and run it try this:
- git clone https://git.elephly.net/software/guile-studio.git
- cd guile-studio
- $(guix build -L guix guile-studio-devel)/bin/guile-studio
+#+BEGIN_SRC sh
+git clone https://git.elephly.net/software/guile-studio.git
+cd guile-studio
+make dist && $(guix build -L guix guile-studio-devel)/bin/guile-studio
+#+END_SRC
diff --git a/guix/rekado/guile-studio.scm b/guix/rekado/guile-studio.scm
index ca14a1e..79e6d8b 100644
--- a/guix/rekado/guile-studio.scm
+++ b/guix/rekado/guile-studio.scm
@@ -8,41 +8,32 @@
(gnu packages guile-xyz)
(gnu packages emacs)
(gnu packages emacs-xyz)
- (gnu packages gnome))
-
-
-;;; XXX big bad hack...
-(system* "tar" "-cf" "/tmp/guile-studio.tar"
- "--exclude-vcs" "--exclude" "guix"
- "-C" "/home/rekado/dev/" "guile-studio")
+ (gnu packages gnome)
+ (gnu packages texinfo))
(define-public guile-studio
(package
(name "guile-studio-devel")
- (version "0")
- (source "/tmp/guile-studio.tar")
+ (version "0.0.1")
+ (source (local-file (string-append "../../guile-studio-" version ".tar.gz")))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ; there are none
+ #:make-flags
+ (list (string-append "ICONS_DIR="
+ (assoc-ref %build-inputs "adwaita-icon-theme")
+ "/share/icons/Adwaita/")
+ (string-append "PICT_DIR="
+ (assoc-ref %build-inputs "guile-picture-language"))
+ (string-append "EMACS_DIR="
+ (assoc-ref %build-inputs "emacs"))
+ (string-append "GUILE_DIR="
+ (assoc-ref %build-inputs "guile"))
+ (string-join (cons "INPUTS=" (map cdr %build-inputs)))
+ (string-append "PREFIX=" (assoc-ref %outputs "out")))
#:phases
(modify-phases %standard-phases
(delete 'configure)
- (replace 'build
- (lambda* (#:key source inputs outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (bin (string-append out "/bin/"))
- (share (string-append out "/share/")))
- (mkdir-p share)
- (mkdir-p bin)
- (apply invoke "guile" "-s"
- "guile-studio-configure.scm"
- out
- (assoc-ref inputs "emacs")
- (assoc-ref inputs "guile-picture-language")
- (string-append (assoc-ref inputs "adwaita-icon-theme")
- "/share/icons/Adwaita/")
- (map cdr inputs))
- #t)))
(delete 'install))))
(inputs
`(("guile" ,guile-2.2)
@@ -54,6 +45,8 @@
("emacs-smart-mode-line" ,emacs-smart-mode-line)
("emacs-paren-face" ,emacs-paren-face)
("adwaita-icon-theme" ,adwaita-icon-theme)))
+ (native-inputs
+ `(("texinfo" ,texinfo)))
(home-page "https://gnu.org/software/guile")
(synopsis "Totally not a cheap copy of Dr Racket for Guile")
(description