aboutsummaryrefslogtreecommitdiff
dnl -*- Autoconf -*- fragment for the C++ daemon.

AC_MSG_CHECKING([whether to build daemon])
AC_MSG_RESULT([$guix_build_daemon])

dnl C++ environment.  This macro must be used unconditionnaly.
AC_PROG_CXX
AM_PROG_AR
AC_LANG([C++])

if test "x$guix_build_daemon" = "xyes"; then

  GUIX_ASSERT_CXX11

  AC_PROG_RANLIB
  AC_CONFIG_HEADERS([nix/config.h])

  dnl Use 64-bit file system calls so that we can support files > 2 GiB.
  AC_SYS_LARGEFILE

  dnl Look for zlib, a required dependency.
  AC_CHECK_LIB([z], [gzdopen], [true],
    [AC_MSG_ERROR([Guix requires zlib.  See http://www.zlib.net/.])])
  AC_CHECK_HEADERS([zlib.h], [true],
    [AC_MSG_ERROR([Guix requires zlib.  See http://www.zlib.net/.])])

  dnl Look for libbz2, an optional dependency.
  AC_CHECK_LIB([bz2], [BZ2_bzWriteOpen], [HAVE_LIBBZ2=yes], [HAVE_LIBBZ2=no])
  if test "x$HAVE_LIBBZ2" = xyes; then
    AC_CHECK_HEADERS([bzlib.h])
    HAVE_LIBBZ2="$ac_cv_header_bzlib_h"
  fi

  dnl Look for SQLite, a required dependency.
  PKG_CHECK_MODULES([SQLITE3], [sqlite3 >= 3.6.19])

  AC_DEFINE_UNQUOTED([SYSTEM], ["$guix_system"],
    [Guix host system type--i.e., platform and OS kernel tuple.])

  case "$LIBGCRYPT_PREFIX" in
    no)
      LIBGCRYPT_CFLAGS=""
      ;;
    *)
      LIBGCRYPT_CFLAGS="-I$LIBGCRYPT_PREFIX/include"
      ;;
  esac

  case "$LIBGCRYPT_LIBDIR" in
    no | "")
      LIBGCRYPT_LIBS="-lgcrypt"
      ;;
    *)
      LIBGCRYPT_LIBS="-L$LIBGCRYPT_LIBDIR -lgcrypt"
      ;;
  esac

  AC_SUBST([LIBGCRYPT_CFLAGS])
  AC_SUBST([LIBGCRYPT_LIBS])

  save_CFLAGS="$CFLAGS"
  save_LDFLAGS="$LDFLAGS"
  CFLAGS="$CFLAGS $LIBGCRYPT_CFLAGS"
  LDFLAGS="$LDFLAGS $LIBGCRYPT_LDFLAGS"

  have_gcrypt=yes
  AC_CHECK_LIB([gcrypt], [gcry_md_open], [:], [have_gcrypt=no])
  AC_CHECK_HEADER([gcrypt.h], [:], [have_gcrypt=no])
  if test "x$have_gcrypt" != "xyes"; then
    AC_MSG_ERROR([GNU libgcrypt not found; please install it.])
  fi

  CFLAGS="$save_CFLAGS"
  LDFLAGS="$save_LDFLAGS"

  dnl Chroot support.
  AC_CHECK_FUNCS([chroot unshare])
  AC_CHECK_HEADERS([sched.h sys/param.h sys/mount.h sys/syscall.h])

  if test "x$ac_cv_func_chroot" != "xyes"; then
    AC_MSG_ERROR(['chroot' function missing, bailing out])
  fi

  dnl lutimes and lchown: used when canonicalizing store items.
  dnl posix_fallocate: used when extracting archives.
  dnl vfork: to speed up spawning of helper programs.
  dnl   `--> now disabled because of unpredictable behavior:
  dnl        see <http://lists.gnu.org/archive/html/guix-devel/2014-05/msg00036.html>
  dnl        and Nix commit f794465c (Nov. 2012).
  dnl sched_setaffinity: to improve RPC locality.
  dnl statvfs: to detect disk-full conditions.
  dnl strsignal: for error reporting.
  dnl statx: fine-grain 'stat' call, new in glibc 2.28.
  AC_CHECK_FUNCS([lutimes lchown posix_fallocate sched_setaffinity \
     statvfs nanosleep strsignal statx])

  dnl Check for <locale>.
  AC_LANG_PUSH(C++)
  AC_CHECK_HEADERS([locale])
  AC_LANG_POP(C++)


  dnl Check whether we have the `personality' syscall, which allows us
  dnl to do i686-linux builds on x86_64-linux machines.
  AC_CHECK_HEADERS([sys/personality.h])

  dnl Determine the appropriate default list of substitute URLs (GnuTLS
  dnl is required so we can default to 'https'.)
  GUIX_SUBSTITUTE_URLS="https://bordeaux.guix.gnu.org https://ci.guix.gnu.org"

  AC_MSG_CHECKING([for default substitute URLs])
  AC_MSG_RESULT([$GUIX_SUBSTITUTE_URLS])
  AC_SUBST([GUIX_SUBSTITUTE_URLS])

  AC_DEFINE_UNQUOTED([GUIX_SUBSTITUTE_URLS], ["$GUIX_SUBSTITUTE_URLS"],
    [Default list of substitute URLs used by 'guix-daemon'.])

  dnl Check for Guile-SSH, which is required by 'guix offload'.
  GUIX_CHECK_GUILE_SSH

  case "x$guix_cv_have_recent_guile_ssh" in
    xyes)
      guix_build_daemon_offload="yes"
      AC_DEFINE([HAVE_DAEMON_OFFLOAD_HOOK], [1],
	[Define if the daemon's 'offload' build hook is being built (requires Guile-SSH).])
      ;;
    *)
      guix_build_daemon_offload="no"
      ;;
  esac

  dnl Temporary directory used to store the daemon's data.
  GUIX_TEST_ROOT_DIRECTORY
  GUIX_TEST_ROOT="$ac_cv_guix_test_root"
  AC_SUBST([GUIX_TEST_ROOT])

  GUIX_CHECK_LOCALSTATEDIR
fi

AM_CONDITIONAL([HAVE_LIBBZ2], [test "x$HAVE_LIBBZ2" = "xyes"])
AM_CONDITIONAL([BUILD_DAEMON], [test "x$guix_build_daemon" = "xyes"])
AM_CONDITIONAL([BUILD_DAEMON_OFFLOAD],			\
  [test "x$guix_build_daemon" = "xyes"			\
   && test "x$guix_build_daemon_offload" = "xyes"])
/packages/agda.scm?id=981cdc901179d8feb4bdde5eefe1930ce32bb0d0'>plainabout -rw-r--r--aidc.scm9232logplainabout -rw-r--r--algebra.scm63946logplainabout -rw-r--r--android.scm43928logplainabout -rw-r--r--animation.scm12586logplainabout -rw-r--r--anthy.scm2879logplainabout -rw-r--r--antivirus.scm7358logplainabout -rw-r--r--apl.scm2193logplainabout -rw-r--r--apr.scm4303logplainabout -rw-r--r--arcan.scm11296logplainabout -rw-r--r--aspell.scm17618logplainabout -rw-r--r--assembly.scm20045logplainabout -rw-r--r--astronomy.scm14705logplainabout -rw-r--r--attr.scm2879logplainabout -rw-r--r--audio.scm190857logplainabout -rw-r--r--augeas.scm2648logplainabout -rw-r--r--authentication.scm5564logplainabout -rw-r--r--autogen.scm3228logplainabout -rw-r--r--autotools.scm22161logplainabout d---------aux-files191logplain -rw-r--r--avahi.scm4851logplainabout -rw-r--r--avr.scm8793logplainabout -rw-r--r--axoloti.scm29514logplainabout -rw-r--r--backup.scm47281logplainabout -rw-r--r--base.scm61636logplainabout -rw-r--r--bash.scm18137logplainabout -rw-r--r--batik.scm8852logplainabout -rw-r--r--bdw-gc.scm5842logplainabout -rw-r--r--benchmark.scm11068logplainabout -rw-r--r--bioconductor.scm318897logplainabout -rw-r--r--bioinformatics.scm634192logplainabout -rw-r--r--bison.scm3561logplainabout -rw-r--r--bittorrent.scm21623logplainabout -rw-r--r--boost.scm15962logplainabout -rw-r--r--bootloaders.scm47298logplainabout -rw-r--r--bootstrap.scm36479logplainabout -rw-r--r--build-tools.scm18727logplainabout -rw-r--r--busybox.scm6870logplainabout -rw-r--r--c.scm19472logplainabout -rw-r--r--calcurse.scm3490logplainabout -rw-r--r--calendar.scm14574logplainabout -rw-r--r--ccache.scm2476logplainabout -rw-r--r--cdrom.scm42663logplainabout -rw-r--r--cedille.scm5517logplainabout -rw-r--r--certs.scm8921logplainabout -rw-r--r--check.scm107683logplainabout -rw-r--r--chemistry.scm19952logplainabout -rw-r--r--chez.scm27586logplainabout -rw-r--r--chicken.scm2767logplainabout -rw-r--r--chromium.scm40697logplainabout -rw-r--r--ci.scm8078logplainabout -rw-r--r--cinnamon.scm3114logplainabout -rw-r--r--clojure.scm13308logplainabout -rw-r--r--cluster.scm10117logplainabout -rw-r--r--cmake.scm16640logplainabout -rw-r--r--cobol.scm2997logplainabout -rw-r--r--code.scm36991logplainabout -rw-r--r--commencement.scm159535logplainabout -rw-r--r--compression.scm96901logplainabout -rw-r--r--compton.scm5982logplainabout -rw-r--r--configuration-management.scm5882logplainabout -rw-r--r--conky.scm3501logplainabout -rw-r--r--connman.scm7259logplainabout -rw-r--r--convmv.scm2300logplainabout -rw-r--r--cook.scm4102logplainabout -rw-r--r--coq.scm26101logplainabout -rw-r--r--cpio.scm1971logplainabout -rw-r--r--cpp.scm26575logplainabout -rw-r--r--cppi.scm1775logplainabout -rw-r--r--cran.scm876839logplainabout -rw-r--r--crates-io.scm1038604logplainabout -rw-r--r--cross-base.scm26185logplainabout -rw-r--r--crypto.scm53821logplainabout -rw-r--r--cryptsetup.scm6228logplainabout -rw-r--r--cups.scm38996logplainabout -rw-r--r--curl.scm13975logplainabout -rw-r--r--cvassistant.scm3640logplainabout -rw-r--r--cybersecurity.scm1791logplainabout -rw-r--r--cyrus-sasl.scm3457logplainabout -rw-r--r--databases.scm148239logplainabout -rw-r--r--datamash.scm1969logplainabout -rw-r--r--datastructures.scm15260logplainabout -rw-r--r--dav.scm7152logplainabout -rw-r--r--dbm.scm6345logplainabout -rw-r--r--dc.scm2233logplainabout -rw-r--r--debian.scm11912logplainabout -rw-r--r--debug.scm28732logplainabout -rw-r--r--dejagnu.scm3510logplainabout -rw-r--r--dhall.scm6289logplainabout -rw-r--r--dico.scm3614logplainabout -rw-r--r--dictionaries.scm16038logplainabout -rw-r--r--diffoscope.scm15835logplainabout -rw-r--r--digest.scm2614logplainabout -rw-r--r--direct-connect.scm2610logplainabout -rw-r--r--disk.scm41778logplainabout -rw-r--r--display-managers.scm14399logplainabout -rw-r--r--distributed.scm4117logplainabout -rw-r--r--django.scm50470logplainabout -rw-r--r--djvu.scm4392logplainabout -rw-r--r--dlang.scm17691logplainabout -rw-r--r--dns.scm49970logplainabout -rw-r--r--docbook.scm13100logplainabout -rw-r--r--docker.scm32934logplainabout -rw-r--r--documentation.scm14158logplainabout -rw-r--r--drones.scm7632logplainabout -rw-r--r--dunst.scm3744logplainabout -rw-r--r--dvtm.scm2311logplainabout -rw-r--r--easyrpg.scm4508logplainabout -rw-r--r--ebook.scm22499logplainabout -rw-r--r--ed.scm2378logplainabout -rw-r--r--education.scm42685logplainabout -rw-r--r--efi.scm8435logplainabout -rw-r--r--electronics.scm10712logplainabout -rw-r--r--elf.scm11087logplainabout -rw-r--r--elixir.scm4965logplainabout -rw-r--r--elm.scm3960logplainabout -rw-r--r--emacs-xyz.scm957497logplainabout -rw-r--r--emacs.scm22127logplainabout -rw-r--r--embedded.scm61206logplainabout -rw-r--r--emulators.scm84157logplainabout -rw-r--r--enchant.scm6539logplainabout -rw-r--r--engineering.scm115831logplainabout -rw-r--r--enlightenment.scm25029logplainabout -rw-r--r--entr.scm3036logplainabout -rw-r--r--erlang.scm10108logplainabout -rw-r--r--fabric-management.scm9621logplainabout -rw-r--r--fcitx.scm7240logplainabout -rw-r--r--figlet.scm1797logplainabout -rw-r--r--file-systems.scm36886logplainabout -rw-r--r--file.scm2273logplainabout -rw-r--r--finance.scm64517logplainabout -rw-r--r--firmware.scm25641logplainabout -rw-r--r--flashing-tools.scm18428logplainabout -rw-r--r--flex.scm3224logplainabout -rw-r--r--fltk.scm6093logplainabout -rw-r--r--fonts.scm82440logplainabout -rw-r--r--fontutils.scm38307logplainabout -rw-r--r--forth.scm2430logplainabout -rw-r--r--fpga.scm15311logplainabout -rw-r--r--freedesktop.scm86094logplainabout -rw-r--r--freeipmi.scm2148logplainabout -rw-r--r--fribidi.scm4068logplainabout -rw-r--r--ftp.scm10969logplainabout -rw-r--r--fvwm.scm3121logplainabout -rw-r--r--game-development.scm100470logplainabout -rw-r--r--games.scm481995logplainabout -rw-r--r--gawk.scm3785logplainabout -rw-r--r--gcal.scm2889logplainabout -rw-r--r--gcc.scm48310logplainabout -rw-r--r--gd.scm6392logplainabout -rw-r--r--gdb.scm6848logplainabout -rw-r--r--genealogy.scm4598logplainabout -rw-r--r--genimage.scm8389logplainabout -rw-r--r--geo.scm87658logplainabout -rw-r--r--gettext.scm10711logplainabout -rw-r--r--ghostscript.scm16882logplainabout -rw-r--r--gimp.scm20625logplainabout -rw-r--r--gkrellm.scm2449logplainabout -rw-r--r--gl.scm42794logplainabout -rw-r--r--glib.scm47005logplainabout -rw-r--r--gnome-xyz.scm25872logplainabout -rw-r--r--gnome.scm458572logplainabout -rw-r--r--gnu-doc.scm4109logplainabout -rw-r--r--gnu-pw-mgr.scm2578logplainabout -rw-r--r--gnucash.scm13605logplainabout -rw-r--r--gnunet.scm16871logplainabout -rw-r--r--gnupg.scm46917logplainabout -rw-r--r--gnustep.scm11894logplainabout -rw-r--r--gnuzilla.scm74135logplainabout -rw-r--r--gobby.scm7738logplainabout -rw-r--r--golang.scm231816logplainabout -rw-r--r--gperf.scm2354logplainabout -rw-r--r--gpodder.scm7738logplainabout -rw-r--r--gps.scm11925logplainabout -rw-r--r--graph.scm20121logplainabout -rw-r--r--graphics.scm69070logplainabout -rw-r--r--graphviz.scm14594logplainabout -rw-r--r--groff.scm11345logplainabout -rw-r--r--groovy.scm47226logplainabout -rw-r--r--gsasl.scm4354logplainabout -rw-r--r--gstreamer.scm35038logplainabout -rw-r--r--gtk.scm87491logplainabout -rw-r--r--guile-wm.scm9353logplainabout -rw-r--r--guile-xyz.scm160827logplainabout -rw-r--r--guile.scm34225logplainabout -rw-r--r--gv.scm3247logplainabout -rw-r--r--gxmessage.scm2352logplainabout -rw-r--r--hardware.scm19312logplainabout -rw-r--r--haskell-apps.scm37314logplainabout -rw-r--r--haskell-check.scm38681logplainabout -rw-r--r--haskell-crypto.scm33163logplainabout -rw-r--r--haskell-web.scm74497logplainabout -rw-r--r--haskell-xyz.scm555840logplainabout -rw-r--r--haskell.scm29623logplainabout -rw-r--r--heads.scm6863logplainabout -rw-r--r--hexedit.scm4680logplainabout -rw-r--r--hugs.scm3688logplainabout -rw-r--r--hurd.scm26662logplainabout -rw-r--r--hyperledger.scm8802logplainabout -rw-r--r--i2p.scm5314logplainabout -rw-r--r--ibus.scm30436logplainabout -rw-r--r--icu4c.scm7817logplainabout -rw-r--r--idris.scm13165logplainabout -rw-r--r--idutils.scm2816logplainabout -rw-r--r--image-processing.scm40523logplainabout -rw-r--r--image-viewers.scm27347logplainabout -rw-r--r--image.scm91060logplainabout -rw-r--r--imagemagick.scm9486logplainabout -rw-r--r--inklingreader.scm2239logplainabout -rw-r--r--inkscape.scm12728logplainabout -rw-r--r--installers.scm6869logplainabout -rw-r--r--ipfs.scm12751logplainabout -rw-r--r--irc.scm22352logplainabout -rw-r--r--iso-codes.scm4113logplainabout -rw-r--r--jami.scm19573logplainabout -rw-r--r--java-compression.scm13773logplainabout -rw-r--r--java-graphics.scm5224logplainabout -rw-r--r--java-maths.scm3603logplainabout -rw-r--r--java.scm561200logplainabout -rw-r--r--javascript.scm20432logplainabout -rw-r--r--jemalloc.scm3391logplainabout -rw-r--r--jose.scm1999logplainabout -rw-r--r--jrnl.scm2437logplainabout -rw-r--r--julia-xyz.scm1813logplainabout -rw-r--r--julia.scm21821logplainabout -rw-r--r--jupyter.scm7701logplainabout -rw-r--r--kawa.scm2553logplainabout -rw-r--r--kde-frameworks.scm151504logplainabout -rw-r--r--kde-internet.scm17761logplainabout -rw-r--r--kde-multimedia.scm27427logplainabout -rw-r--r--kde-pim.scm73719logplainabout -rw-r--r--kde-plasma.scm8178logplainabout -rw-r--r--kde-systemtools.scm11918logplainabout -rw-r--r--kde-utils.scm20419logplainabout -rw-r--r--kde.scm29573logplainabout -rw-r--r--kerberos.scm10177logplainabout -rw-r--r--key-mon.scm2121logplainabout -rw-r--r--kodi.scm21504logplainabout -rw-r--r--language.scm41438logplainabout -rw-r--r--ld-wrapper.in12323logplainabout -rw-r--r--lean.scm3109logplainabout -rw-r--r--lego.scm5443logplainabout -rw-r--r--less.scm4653logplainabout -rw-r--r--lesstif.scm1817logplainabout -rw-r--r--libbsd.scm2157logplainabout -rw-r--r--libcanberra.scm6111logplainabout -rw-r--r--libdaemon.scm3621logplainabout -rw-r--r--libedit.scm2839logplainabout -rw-r--r--libevent.scm9679logplainabout -rw-r--r--libffcall.scm1922logplainabout -rw-r--r--libffi.scm10886logplainabout -rw-r--r--libftdi.scm1943logplainabout -rw-r--r--libidn.scm3562logplainabout -rw-r--r--libphidget.scm1747logplainabout -rw-r--r--libreoffice.scm49635logplainabout -rw-r--r--libsigsegv.scm2731logplainabout -rw-r--r--libunistring.scm3159logplainabout -rw-r--r--libunwind.scm2318logplainabout -rw-r--r--libusb.scm25555logplainabout -rw-r--r--license.scm8410logplainabout -rw-r--r--lighting.scm3690logplainabout -rw-r--r--linphone.scm27112logplainabout