tests: Run without substitutes.
[jackhill/guix/guix.git] / Makefile.am
CommitLineData
af51c820
LC
1# Guix --- Nix package management from Guile. -*- coding: utf-8 -*-
2# Copyright (C) 2012 Ludovic Courtès <ludo@gnu.org>
3#
4# This file is part of Guix.
5#
6# Guix is free software; you can redistribute it and/or modify it
7# under the terms of the GNU General Public License as published by
8# the Free Software Foundation; either version 3 of the License, or (at
9# your option) any later version.
10#
11# Guix is distributed in the hope that it will be useful, but
12# WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public License
17# along with Guix. If not, see <http://www.gnu.org/licenses/>.
18
c52a5bf0
LC
19bin_SCRIPTS = \
20 guix-build \
0afdc485
LC
21 guix-download \
22 guix-package
14a1c319 23
af51c820 24MODULES = \
73fbb904 25 guix/utils.scm \
af51c820 26 guix/derivations.scm \
208f7cd1
LC
27 guix/build-system.scm \
28 guix/build-system/gnu.scm \
be13fbfa 29 guix/build-system/trivial.scm \
457dd86d
LC
30 guix/ftp.scm \
31 guix/ftp-client.scm \
af51c820
LC
32 guix/http.scm \
33 guix/store.scm \
073c34d7 34 guix/ui.scm \
af51c820 35 guix/build/gnu-build-system.scm \
457dd86d 36 guix/build/ftp.scm \
af51c820 37 guix/build/http.scm \
1273d44a 38 guix/build/utils.scm \
c8c88afa 39 guix/build/union.scm \
e3ce5d70
LC
40 guix/packages.scm \
41 guix.scm \
6b1891b0 42 distro.scm \
1f455fdc 43 distro/packages/base.scm \
1722d680
LC
44 distro/packages/databases.scm \
45 distro/packages/guile.scm \
46 distro/packages/ld-wrapper.scm \
47 distro/packages/typesetting.scm
af51c820
LC
48
49GOBJECTS = $(MODULES:%.scm=%.go)
50
800cdeef
LC
51nobase_dist_guilemodule_DATA = $(MODULES)
52
53patchdir = $(pkgdatadir)/patches
bfb3c3d0
LC
54dist_patch_DATA = \
55 distro/packages/patches/binutils-ld-new-dtags.patch \
56 distro/packages/patches/diffutils-gets-undeclared.patch \
57 distro/packages/patches/guile-1.8-cpp-4.5.patch \
58 distro/packages/patches/guile-default-utf8.patch \
59 distro/packages/patches/guile-relocatable.patch \
60 distro/packages/patches/libtool-skip-tests.patch \
61 distro/packages/patches/m4-gets-undeclared.patch \
62 distro/packages/patches/m4-readlink-EINVAL.patch \
63 distro/packages/patches/m4-s_isdir.patch \
64 distro/packages/patches/make-impure-dirs.patch \
65 distro/packages/patches/findutils-absolute-paths.patch \
66 distro/packages/patches/perl-no-sys-dirs.patch \
67 distro/packages/patches/readline-link-ncurses.patch \
68 distro/packages/patches/tar-gets-undeclared.patch
d7672884 69
ac5aa288
LC
70bootstrapdir = $(pkgdatadir)/bootstrap
71bootstrap_x86_64_linuxdir = $(bootstrapdir)/x86_64-linux
d25468bc 72bootstrap_i686_linuxdir = $(bootstrapdir)/i686-linux
ac5aa288
LC
73
74dist_bootstrap_x86_64_linux_DATA = \
75 distro/packages/bootstrap/x86_64-linux/bash \
76 distro/packages/bootstrap/x86_64-linux/mkdir \
77 distro/packages/bootstrap/x86_64-linux/tar \
78 distro/packages/bootstrap/x86_64-linux/xz
79
d25468bc
LC
80dist_bootstrap_i686_linux_DATA = \
81 distro/packages/bootstrap/i686-linux/bash \
82 distro/packages/bootstrap/i686-linux/mkdir \
83 distro/packages/bootstrap/i686-linux/tar \
84 distro/packages/bootstrap/i686-linux/xz
85
ac5aa288
LC
86# Big bootstrap binaries are not included in the tarball. Instead, they
87# are downloaded.
88nodist_bootstrap_x86_64_linux_DATA = \
89 distro/packages/bootstrap/x86_64-linux/guile-bootstrap-2.0.6.tar.xz
d25468bc
LC
90nodist_bootstrap_i686_linux_DATA = \
91 distro/packages/bootstrap/i686-linux/guile-bootstrap-2.0.6.tar.xz
ac5aa288 92
5992f213
LC
93# Those files must remain executable, so they remain executable once
94# imported into the store.
95install-data-hook:
96 chmod +x $(DESTDIR)$(bootstrapdir)/*/{bash,mkdir,tar,xz}
97
d25468bc
LC
98DISTCLEANFILES = \
99 $(nodist_bootstrap_x86_64_linux_DATA) \
100 $(nodist_bootstrap_i686_linux_DATA)
ac5aa288
LC
101
102# Method to download a file from an external source.
103DOWNLOAD_FILE = \
104 GUILE_LOAD_COMPILED_PATH="$(top_builddir):$$GUILE_LOAD_COMPILED_PATH" \
105 $(GUILE) --no-auto-compile -L "$(top_srcdir)" \
106 "$(top_srcdir)/build-aux/download.scm"
107
108distro/packages/bootstrap/x86_64-linux/guile-bootstrap-2.0.6.tar.xz: guix/utils.go
735bb2af 109 $(MKDIR_P) `dirname "$@"`
ac5aa288 110 $(DOWNLOAD_FILE) "$@" "0467a82cbe4136f60a79eb4176011bf88cf28ea19c9ad9defa365811ff8e11cf"
d25468bc 111distro/packages/bootstrap/i686-linux/guile-bootstrap-2.0.6.tar.xz: guix/utils.go
735bb2af 112 $(MKDIR_P) `dirname "$@"`
d25468bc 113 $(DOWNLOAD_FILE) "$@" "93b537766dfab3ad287143523751e3ec02dd32d3ccaf88ad2d31c63158f342ee"
ac5aa288 114
af51c820
LC
115nobase_nodist_guilemodule_DATA = $(GOBJECTS)
116
117TESTS = \
118 tests/builders.scm \
119 tests/derivations.scm \
e3ce5d70 120 tests/utils.scm \
b0e0d0e9 121 tests/build-utils.scm \
c8c88afa 122 tests/packages.scm \
97298ffa 123 tests/union.scm \
0afdc485
LC
124 tests/guix-build.sh \
125 tests/guix-package.sh
af51c820 126
97298ffa
LC
127TEST_EXTENSIONS = .scm .sh
128
129SCM_LOG_COMPILER = $(top_builddir)/pre-inst-env $(GUILE)
130AM_SCM_LOG_FLAGS = --no-auto-compile -L "$(top_srcdir)"
131
132SH_LOG_COMPILER = $(top_builddir)/pre-inst-env $(SHELL)
133AM_SH_LOG_FLAGS = -x -e
af51c820 134
ed795c06 135EXTRA_DIST = \
450ccdc3 136 HACKING \
1722d680 137 .dir-locals.el \
ac5aa288 138 build-aux/download.scm \
ed795c06
LC
139 srfi/srfi-64.scm \
140 srfi/srfi-64.upstream.scm \
d95c0113 141 tests/test.drv \
ed795c06
LC
142 build-aux/config.rpath \
143 release.nix \
144 $(TESTS)
d7672884 145
af51c820
LC
146CLEANFILES = $(GOBJECTS) *.log
147
148.scm.go:
149 $(MKDIR_P) `dirname "$@"`
fc2f3802
LC
150 DISTRO_INSTALLED_PATCH_DIRECTORY="$(patchdir)" \
151 DISTRO_INSTALLED_BOOTSTRAP_DIRECTORY="$(bootstrapdir)" \
152 $(top_builddir)/pre-inst-env \
153 $(GUILD) compile -L "$(top_srcdir)" \
154 -Wformat -Wunbound-variable -Warity-mismatch \
155 --target="$(host)" \
af51c820
LC
156 -o "$@" "$<"
157
158SUFFIXES = .go
159
160# Make sure source files are installed first, so that the mtime of
161# installed compiled files is greater than that of installed source
162# files. See
163# <http://lists.gnu.org/archive/html/guile-devel/2010-07/msg00125.html>
164# for details.
165guix_install_go_files = install-nobase_nodist_guilemoduleDATA
166$(guix_install_go_files): install-nobase_dist_guilemoduleDATA
f68b0893
LC
167
168SUBDIRS = po
169
568717fd
LC
170info_TEXINFOS = doc/guix.texi
171EXTRA_DIST += doc/fdl-1.3.texi
172
f68b0893 173ACLOCAL_AMFLAGS = -I m4
437e0729
LC
174AM_DISTCHECK_CONFIGURE_FLAGS = \
175 --with-nixpkgs=$(NIXPKGS) --with-nix-prefix="$(NIX_PREFIX)"