Sage under Cygwin64

73 views
Skip to first unread message

Miguel Karlsruhe

unread,
Jul 26, 2019, 6:20:55 AM7/26/19
to sage-devel
Hi group,

Running 'make' of Sage-8.8-Ubuntu_18.04-x86_64.tar.bz2 under Cygwin64 shell (Windows 10), I get the following building error:

[zlib-1.2.11.p0] Building zlib-1.2.11.p0
[zlib-1.2.11.p0] make[3]: Entering directory '/home/SageMath/local/var/tmp/sage/build/zlib-1.2.11.p0/src'
[zlib-1.2.11.p0] gcc  -O3 -Wall -c -o adler32.o adler32.c
[zlib-1.2.11.p0] /home/SageMath/local/bin/gcc: /home/SageMath/local/bin/gcc: cannot execute binary file
[zlib-1.2.11.p0] make[3]: *** [Makefile:85: adler32.o] Error 126
[zlib-1.2.11.p0] make[3]: Leaving directory '/home/SageMath/local/var/tmp/sage/build/zlib-1.2.11.p0/src'
[zlib-1.2.11.p0] ********************************************************************************
[zlib-1.2.11.p0] Error building zlib-1.2.11.p0
[zlib-1.2.11.p0] ********************************************************************************
[zlib-1.2.11.p0]
[zlib-1.2.11.p0] real   0m0.949s
[zlib-1.2.11.p0] user   0m0.105s
[zlib-1.2.11.p0] sys    0m0.412s
[zlib-1.2.11.p0] ************************************************************************
[zlib-1.2.11.p0] Error installing package zlib-1.2.11.p0
[zlib-1.2.11.p0] ************************************************************************
[zlib-1.2.11.p0] Please email sage-devel (http://groups.google.com/group/sage-devel)
[zlib-1.2.11.p0] explaining the problem and including the log file
[zlib-1.2.11.p0]   /home/SageMath/logs/pkgs/zlib-1.2.11.p0.log
[zlib-1.2.11.p0] Describe your computer, operating system, etc.
[zlib-1.2.11.p0] If you want to try to fix the problem yourself, *don't* just cd to
[zlib-1.2.11.p0] /home/SageMath/local/var/tmp/sage/build/zlib-1.2.11.p0 and type 'make' or whatever is appropriate.
[zlib-1.2.11.p0] Instead, the following commands setup all environment variables
[zlib-1.2.11.p0] correctly and load a subshell for you to debug the error:
[zlib-1.2.11.p0]   (cd '/home/SageMath/local/var/tmp/sage/build/zlib-1.2.11.p0' && '/home/SageMath/sage' --sh)
[zlib-1.2.11.p0] When you are done debugging, you can type "exit" to leave the subshell.
[zlib-1.2.11.p0] ************************************************************************
make[2]: *** [Makefile:2163: /home/SageMath/local/var/lib/sage/installed/zlib-1.2.11.p0] Error 1
make[2]: Leaving directory '/home/SageMath/build/make'
make[1]: *** [Makefile:1852: base-toolchain] Error 2
make[1]: Leaving directory '/home/SageMath/build/make'

real    0m18.784s
user    0m1.174s
sys     0m3.768s
***************************************************************
Error building Sage.

The following package(s) may have failed to build (not necessarily
during this run of 'make base-toolchain'):

* package: zlib-1.2.11.p0
  log file: /home/SageMath/logs/pkgs/zlib-1.2.11.p0.log
  build directory: /home/SageMath/local/var/tmp/sage/build/zlib-1.2.11.p0

The build directory may contain configuration files and other potentially
helpful information. WARNING: if you now run 'make' again, the build
directory will, by default, be deleted. Set the environment variable
SAGE_KEEP_BUILT_SPKGS to 'yes' to prevent this.

make: *** [Makefile:33: base-toolchain] Error 1

#####

Environmental variable: echo $SAGE_KEEP_BUILT_SPKGS
yes

#####

Any help? Thanks a lot,
Miguel
config.log
config.log
zlib-1.2.11.p0.log

Dima Pasechnik

unread,
Jul 26, 2019, 6:41:31 AM7/26/19
to sage-devel
install gcc, g++, gfortran packages from your Cygwin64; you also don't need to build zlib, Sage can use the installed zlib, as well as many other.

--
You received this message because you are subscribed to the Google Groups "sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-devel/586886c6-2437-4d25-a78a-4a8c8b008aa6%40googlegroups.com.

Dima Pasechnik

unread,
Jul 26, 2019, 6:44:55 AM7/26/19
to sage-devel

E. Madison Bray

unread,
Jul 26, 2019, 10:13:24 AM7/26/19
to sage-devel
On Fri, Jul 26, 2019 at 12:44 PM Dima Pasechnik <dim...@gmail.com> wrote:
None of this is relevant to the OP.  Please read carefully:

> Running 'make' of Sage-8.8-Ubuntu_18.04-x86_64.tar.bz2 under Cygwin64 shell

Miguel, you are trying to run a Linux binary on Cygwin.  That won't work, and it isn't how Cygwin works--it cannot run Linux binaries.  It *does* work in the Windows Subsystem for Linux (WSL) shell, if you have that installed.

What are you actually trying to do?  Providing any further advice would depend entirely on that :)

Samuel Lelievre

unread,
Aug 1, 2019, 12:00:44 PM8/1/19
to sage-devel
Miguel,

Installation options under Windows 10 include the following three:

- activate Microsoft's "Windows Subsystem for Linux" (WSL);
  for that, provided you have admin rights on that computer,
  follow the official instructions at


  Then, install Linux in the WSL, and either use SageMath binaries
  for Linux as found on the download page at


  or install from source in that Linux environment.

- use Cygwin and build from source; for this follow instructions at


- use the SageMath installer for Windows (aka "Sage-Windows");
  see documentation at


  This installs a Cygwin layer and a ready-to-go SageMath in it.
  It puts startup icons on the Windows desktop for running either
  - SageMath in the Jupyter Notebook server
  - the SageMath REPL (or read-eval-print loop),
    also known as the command line interface,
    or "Sage in the terminal"
  - the Sage shell, a terminal window where one can type in
    commands to install extra packages for Sage or Cygwin.

Kind regards,
Samuel
Reply all
Reply to author
Forward
0 new messages