Building JS library from scratch

News and discussion of the PC port of Oolite.

Moderators: winston, another_commander

Post Reply
User avatar
mcarans
---- E L I T E ----
---- E L I T E ----
Posts: 388
Joined: Sun Jun 20, 2010 6:00 pm

Building JS library from scratch

Post by mcarans »

I ran this to get configure in deps\mozilla\js\src as far as possible:

Code: Select all

export CC=/mingw64/bin/gcc
export CXX=/mingw64/bin/g++
./configure --with-windows-version=502
This failed needing Python < 3:

Code: Select all

$ ./configure --with-windows-version=502
loading site script /etc/config.site
loading cache ./config.cache
checking host system type... x86_64-pc-mingw32
checking target system type... x86_64-pc-mingw32
checking build system type... x86_64-pc-mingw32
checking for mawk... no
checking for gawk... gawk
checking for perl5... no
checking for perl... /usr/bin/perl
checking for gcc... /mingw64/bin/gcc
checking whether the C compiler (/mingw64/bin/gcc  ) works... yes
checking whether the C compiler (/mingw64/bin/gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether /mingw64/bin/gcc accepts -g... yes
checking for c++... /mingw64/bin/g++
checking whether the C++ compiler (/mingw64/bin/g++  ) works... yes
checking whether the C++ compiler (/mingw64/bin/g++  ) is a cross-compiler... no
checking whether we are using GNU C++... yes
checking whether /mingw64/bin/g++ accepts -g... yes
checking for ranlib... ranlib
checking for ml64... no
checking for as... /mingw64/bin/as
checking for ar... ar
checking for ld... link
checking for strip... strip
checking for windres... windres
checking for w32api version >= 3.8... yes
checking for windres version >= 2.14.90... (GNU
./configure: line 3402: test: (GNU: integer expression expected
checking for Windows SDK being recent enough... yes
checking whether /mingw64/bin/gcc and cc understand -c and -o together... yes
checking how to run the C preprocessor... cl -E -nologo
checking how to run the C++ preprocessor... cl -TP -E -nologo
checking for sb-conf... no
checking for ve... no
checking for a BSD compatible install... /usr/bin/install -c
checking whether ln -s works... no
checking for minimum required perl version >= 5.006... 5.038004
checking for full perl installation... yes
checking for python2.7... no
checking for python2.6... no
checking for python2.5... no
checking for python... /mingw64/bin/python
checking for doxygen... :
checking for autoconf... /usr/bin/autoconf
checking for unzip... :
checking for zip... /usr/bin/zip
checking for makedepend... no
checking for xargs... /usr/bin/xargs
checking for make... /usr/bin/make
checking for X... no
checking whether the compiler supports -Wno-invalid-offsetof... yes
checking whether the compiler supports -Wno-variadic-macros... yes
checking whether the compiler supports -Werror=return-type... yes
checking whether ld has archive extraction flags... yes
checking that static assertion macros used in autoconf tests work... yes
checking for 64-bit OS... yes
checking for Python version >= 2.5 but not 3.x... configure: error: Python 2.5 or higher (but not Python 3.x) is required.
I'm not sure it will be possible to build the JS library on any modern setup, but I might try this: https://github.com/msys2/MSYS2-packages/issues/2334 to see how far I can get.
User avatar
mcarans
---- E L I T E ----
---- E L I T E ----
Posts: 388
Joined: Sun Jun 20, 2010 6:00 pm

Re: Building JS library from scratch

Post by mcarans »

Python 2.7 installed fine. There seems to be a need for an env var "MOZ_TOOLS". I'm not sure what it is supposed to point to. If I set it to something, configure fails with "checking for a 1-byte type... configure: error: Couldn't find a 1-byte type"

The code from configure is this:

Code: Select all

echo $ac_n "checking for a 1-byte type""... $ac_c" 1>&6
echo "configure:8634: checking for a 1-byte type" >&5
if eval "test \"`echo '$''{'moz_cv_n_byte_type_JS_INT8_TYPE'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  
  moz_cv_n_byte_type_JS_INT8_TYPE=
  for type in char; do
    cat > conftest.$ac_ext <<EOF
Anyone got any idea what are MOZ_TOOLS and/or what this error is about?
Post Reply