GithubHelp home page GithubHelp logo

vanadium23 / elementum Goto Github PK

View Code? Open in Web Editor NEW

This project forked from elgatito/elementum

0.0 2.0 0.0 2.63 MB

Elementum daemon, for the add-on see

Home Page: https://github.com/elgatito/plugin.video.elementum

Makefile 0.87% Go 98.81% Shell 0.31%

elementum's Introduction

Elementum daemon Build Status

Fork of the great Pulsar daemon and Quasar daemon

Easy development environment set up

There is an easy way to prepare local environment for running/compiling Elementum.

  1. Clone libtorrent-go repository:
git clone [email protected]:ElementumOrg/libtorrent-go.git
  1. Run make local-env that will create local-env directory will all required components.
make local-env
  1. Modify LOCAL-ENV variable in test_build.sh to use local-env directory:
  export LOCAL_ENV=$GOPATH/src/github.com/ElementumOrg/libtorrent-go/local-env/

Or you can apply environment variables and compile in any other way:

  export LOCAL_ENV=$GOPATH/src/github.com/ElementumOrg/libtorrent-go/local-env/
  export PATH=$PATH:$LOCAL_ENV/bin/
  export PKG_CONFIG_PATH=$LOCAL_ENV/lib/pkgconfig
  export SWIG_LIB=$LOCAL_ENV/share/swig/4.1.0/

How to run

  1. Build the cross-compiler images, or alternatively, pull the cross-compiler images from Docker Hub:

    make pull-all
    

    Or for a specific platform:

    make pull PLATFORM=android-x64
    
  2. Set GOPATH

    export GOPATH="~/go"
    
  3. go get

    go get -d github.com/elgatito/elementum
    

    For Windows support, but required for all builds, you also need:

    go get github.com/mattn/go-isatty
    
  4. Build libtorrent-go libraries:

    make libs
    
  5. Make specific platforms, or all of them:

    Linux-x64

    make linux-x64
    

    Darwin-x64

    make darwin-x64
    

    Windows

    make windows-x86
    

    All platforms

    make
    

Find memory leaks

To find memory leaks, we can use Valgrind or use Sanitizers.

/bin/bash test_build.sh sanitize

This will build the binary with enabled sanitizer, so just run it and wait for errors in the console.

valgrind --leak-check=full ./elementum -disableBackup

This will run the binary with Valgrind. When you cose the process, Valgrind will show statistics. It is better to use usual binary, without sanitizer, and add backup disable options, as well as disable Kodi library integration. Or it will take a lot of time/CPU at the startup (unless you do need it).

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.