Git Product home page Git Product logo

hl-recast's Introduction

hl-recast

THIS PROJECT IS IN PROGRESS - DO NOT CLONE, IT DOES NOT WORK

Build and Install

Note: Most of the following steps are common on windows, linux and mac. The only difference is in the build & install step.

1. Prerequisites:

1.1. Install haxe: (: https://haxe.org/download)
1.2. Install hashlink: (https://hashlink.haxe.org )
1.3. Install heaps: (For linux: https://heaps.io/documentation/installation.html )
1.4. Install the modified webidl from git:

haxelib git hl-idl https://github.com/onehundredfeet/hl-idl.git

2. Build

2.1. Clone this repo into a clean directory.

Open new terminal in this directory.

haxelib dev hl-recast hl-recast

This tells haxe to look for the library 'hl-recast' in the directory 'hl-recast'. The 'dev' keyword tells haxe that the library is local and will be directly referenced instead of being installed to the library cache.

2.2 Clone recast c++ sources as a submodule in hl-recast From the hl-recast root, run

git submodule update --init --recursive

2.3 Generate the binding cpp file.

Change directory into the hl-recast root.

.Open new terminal under and run

make genhl

This will generate src/recast.cpp from recast/recast.idl

2.4 Generate cmake and build.
Note: At this step there are differences between platforms
Create new dir : HL-RECAST-ROOT/build
Open new terminal in the directory HL-recast-ROOT/build and run:

For linux:

    cmake ..
      -DRECAST_SRC_DIR="ext/recast" # This is the /src from step 2
      -DHL_INCLUDE_DIR="<path-to-hashlink headers>" # Path to where hashlink headers (hl.h, ...) are located. Usually under ...hashlink-x.xx/src 
      -DHL_LIB_DIR="<path-to-hashlink>" # Path to where hashlink binaries (libhl.so, ...) are located. Usually ...hashlink-x.xx
      -HDLL_DESTINATION="final/install/destination" #The path of all *hdll binaries, usually this is 'usr/lib' or 'usr/local/lib'
    make
    make install

DEVELOPER NOTE: recast WILL REQUIRE MULTIPLE SOURCE DIRS. They have submodules netcode.io reliable.io

specific cmake command example on linux:

    cmake .. -Drecast_SRC_DIR="ext/recast" -DHL_INCLUDE_DIR="/usr/local/include" -DHL_LIB_DIR="/usr/local/lib" -DHDLL_DESTINATION="/usr/local/lib"

For windows:

    cmake .. -A x64 -G "Visual Studio 15 2017" 
    -Drecast_SRC_DIR="<path-to-bullet3>/src" # This is the /src from step 2
      -DHL_INCLUDE_DIR="<path-to-hashlink>/include"
      -DHL_LIB_DIR="<path-to-hashlink>"  # Path to where hashlink binaries (libhl.lib, ...) are located
      -HDLL_DESTINATION="final/install/destination" # Usually <path-to-hashlink>
  • Open and build build/Project.sln
  • Copy ./build/Debug/bullet.hdll to ../path/to/HashLink/hdll/location/ # Just in case Visual Studio install step fails.

For UNIX (Mac / Linux):

  • Note: Specify the hashlink directories on your system. On Mac, brew defaults /usr/local (lib/include).

Ninja is optional. You can use make just by removing -GNinja.

 cmake -GNinja .. -DRECAST_SRC_DIR="ext/recast/Recast" -DHL_INCLUDE_DIR="/usr/local/include" -DHL_LIB_DIR="/usr/local/lib" -DDETOUR_SRC_DIR="ext/recast/Detour" -DHDLL_DESTINATION="/usr/local/lib"
    make
    make install

cmake .. -A x64 -G "Visual Studio 15 2017" -DRECAST_SRC_DIR="C:/Projects/RecastToHL/recastnavigation_cpp/Recast" -DHL_INCLUDE_DIR="C:/HaxeToolkit/HashLink/hl-1.11.0-win/include" -DHL_LIB_DIR="C:/HaxeToolkit/HashLink/hl-1.11.0-win" -DHDLL_DESTINATION="C:/HaxeToolkit/HashLink/hl-1.11.0-win"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.