Help building Haxe 2.10

84 views
Skip to first unread message

theRemix

unread,
Dec 9, 2014, 5:26:50 AM12/9/14
to haxe...@googlegroups.com
i have successfully built neko and haxe v-2.10, however haxelib has never worked for me

here is the output of running haxelib

Uncaught exception - std@module_read


i've tested all combinations of 
  • debian:wheezy
  • ubuntu:trusty
  • gentoo:stage3-amd64-20141204
they all have the same result, working haxe, working neko, broken haxelib, which prevents me from building any haxe projects that have -lib argument.

here is output of haxe -help

Haxe Compiler 2.10 - (c)2005-2012 Motion-Twin
...


output of neko

NekoVM 2.0.0 (c)2005-2013 Haxe Foundation


and here is how i installed haxe and neko on a fresh ubuntu install
echo "Installing Haxe dependencies" && \
    apt-get update && \
    apt-get install -y make libzip-dev ocaml git-core libgc-dev libpcre3-dev apache2-threaded-dev libsqlite3-dev camlp4 || echo "ERROR: Failed to install haxe and ocaml dependencies with apt-get" && \
    cd /tmp && \
    git clone --depth=1 https://github.com/HaxeFoundation/neko.git || echo "Failed to checkout neko source from Github" && \
    cd /tmp/neko && \
    echo "Compile Neko" && \
    make clean all || echo "Failed to run 'make clean all' on neko codebase" && \
    echo "Install Neko" && \
    make install || echo "Failed to run 'make install' on neko codebase" && \
    cd /tmp && \
    git clone --branch v2-10-fix-ocaml4 --depth=1 https://github.com/clemos/haxe.git && \
    cd /tmp/haxe && \
    echo "Compiling Haxe" && \
    make clean all || echo "Failed to run 'make clean all' on haxe codebase" && \
    echo "Install Haxe" && \
    rm -rf /usr/lib/haxe && \
    mkdir -p /usr/lib/haxe && \
    rm -rf /usr/lib/haxe/std && \
    cp -rf std /usr/lib/haxe/std && \
    mkdir -p /usr/lib/haxe/lib && \
    rm -f /usr/bin/haxe && \
    rm -f /usr/bin/haxelib && \
    cp haxe /usr/lib/haxe && \
    cp haxelib /usr/lib/haxe && \
    ln -s /usr/lib/haxe/haxe /usr/bin/haxe && \
    ln -s /usr/lib/haxe/haxelib /usr/bin/haxelib && \
    chmod -R a+rx /usr/lib/haxe && \
    chmod 777 /usr/lib/haxe/lib && \
    chmod a+rx /usr/bin/haxe /usr/bin/haxelib && \
    echo "Haxe Installed"


and here is how i installed haxe and neko on a fresh gentoo install
emerge --sync
    echo "# required by camlp4 (argument)" >> /etc/portage/package.accept_keywords && \
    echo "=dev-ml/camlp4-4.02.0_p1-r1 ~amd64" >> /etc/portage/package.accept_keywords && \
    echo "# required by dev-ml/camlp4-4.02.0_p1-r1" >> /etc/portage/package.accept_keywords && \
    echo "# required by camlp4 (argument)" >> /etc/portage/package.accept_keywords && \
    echo "=dev-lang/ocaml-4.02.1 ~amd64" >> /etc/portage/package.accept_keywords && \
    emerge dev-libs/libzip dev-vcs/git dev-db/sqlite camlp4 || echo "ERROR: Failed to install ocaml with portage" && \
    USE="threads" emerge www-servers/apache dev-libs/boehm-gc || echo "ERROR: Failed to install apache and boehm-gc with portage" && \
    cd /tmp && \
    git clone --depth=1 https://github.com/HaxeFoundation/neko.git || echo "Failed to checkout neko source from Github" && \
    cd /tmp/neko && \
    echo "Compile Neko" && \
    make clean all || echo "Failed to run 'make clean all' on neko codebase" && \
    echo "Install Neko" && \
    make install || echo "Failed to run 'make install' on neko codebase" && \
    cd /tmp && \
    git clone --branch v2-10-fix-ocaml4 --depth=1 https://github.com/clemos/haxe.git && \
    cd /tmp/haxe && \
    echo "Compiling Haxe" && \
    make clean all || echo "Failed to run 'make clean all' on haxe codebase" && \
    echo "Install Haxe" && \
    rm -rf /usr/lib/haxe && \
    mkdir -p /usr/lib/haxe && \
    rm -rf /usr/lib/haxe/std && \
    cp -rf std /usr/lib/haxe/std && \
    mkdir -p /usr/lib/haxe/lib && \
    rm -f /usr/bin/haxe && \
    rm -f /usr/bin/haxelib && \
    cp haxe /usr/lib/haxe && \
    cp haxelib /usr/lib/haxe && \
    ln -s /usr/lib/haxe/haxe /usr/bin/haxe && \
    ln -s /usr/lib/haxe/haxelib /usr/bin/haxelib && \
    chmod -R a+rx /usr/lib/haxe && \
    chmod 777 /usr/lib/haxe/lib && \
    chmod a+rx /usr/bin/haxe /usr/bin/haxelib && \
    echo "Haxe Installed"

any suggestions?

clemos

unread,
Dec 9, 2014, 5:38:48 AM12/9/14
to haxe...@googlegroups.com
Hi,

It seems you need neko 1.8 to compile and/or run Haxe2
Here is a Dockerfile that works for me :
There is quite some renaming you probably don't need 
(because my intent was to install both haxe2 and haxe3 on the same machine),
so that the command is `haxe2` instead of `haxe`, 
but it's rather easy to change.

Best,
Clément

--
To post to this group haxe...@googlegroups.com
http://groups.google.com/group/haxelang?hl=en
---
You received this message because you are subscribed to the Google Groups "Haxe" group.
For more options, visit https://groups.google.com/d/optout.

theRemix

unread,
Dec 9, 2014, 5:45:13 AM12/9/14
to haxe...@googlegroups.com
thanks Clément!

theRemix

unread,
Dec 9, 2014, 4:50:56 PM12/9/14
to haxe...@googlegroups.com
haxelib is working, sort of.

it runs, however, haxelib setup is failing

haxelib setup

Please enter haxelib repository path with write access
Hit enter for default (/usr/lib/haxe/lib)
Path :  
[file_open,null/.haxelib]


have you ever experienced this?


On Tuesday, December 9, 2014 12:38:48 AM UTC-10, clemos wrote:

clemos

unread,
Dec 9, 2014, 5:08:55 PM12/9/14
to haxe...@googlegroups.com
Hi,

Sorry, I wasn't really interested in installing Haxelib, so I never went that far ;)

The relevant code is here :
It's not very clear, but you may start by trying to set an HAXEPATH environment variable, I guess...

Best,
Clément

theRemix

unread,
Dec 11, 2014, 6:22:18 AM12/11/14
to haxe...@googlegroups.com
it does work. thanks!

echo "export HAXEPATH='/usr/lib/haxe/'" >> /root/.bashrc
echo "export HOME='/root'" >> /root/.bashrc
Reply all
Reply to author
Forward
0 new messages