• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

X-Friese/FlyWithLua: A Lua scripting plugin for X-Plane

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

X-Friese/FlyWithLua

开源软件地址(OpenSource Url):

https://github.com/X-Friese/FlyWithLua

开源编程语言(OpenSource Language):

C++ 57.3%

开源软件介绍(OpenSource Introduction):

FlyWithLua for X-Plane 11

CMake

This is the official source code repository for the FlyWithLua plugin project.

FlyWithLua offers Lua scripting to X-Plane since X-Plane 9.

Discussions to general topics should be opened on the official forum at x-plane.org.

You will find a binary version ready to use in X-Plane 9 or 10 in the download area of x-plane.org.

The new versions are X-Plane 11 only and the binary is also in the download area of x-plane.org.

If you want to grab a most nightly binary, just download FlyWithLua_plugin.zip from the most recent GitHub Actions build and unpack it into your X-Plane's plugin folder.

Copyright (c) 2012 Carsten Lynker

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Building FlyWithLua from source

On windows

  1. Install required software using Chocolatey using admin command prompt:

    choco install git cmake
    choco install mingw --version 8.1.0
    

    You can also install the same programs manually if you prefer.

  2. Checkout and configure the project:

    git clone https://github.com/X-Friese/FlyWithLua.git
    cd FlyWithLua
    cmake -G "MinGW Makefiles" -S .\src -B .\build -DCMAKE_BUILD_TYPE=RelWithDebInfo
    
  3. Build the project and copy the plugin DLL into the appropriate directory:

    cmake --build .\build
    cp .\build\win.xpl .\FlyWithLua\64\
    

On Ubuntu:

  1. Install required software:

    sudo apt-get install -y --no-install-recommends build-essential cmake git freeglut3-dev libudev-dev libopenal-dev
    
    
  2. Checkout and configure the project:

    git clone https://github.com/X-Friese/FlyWithLua.git
    cd FlyWithLua
    cmake -S ./src -B ./build -DCMAKE_BUILD_TYPE=RelWithDebInfo
    
  3. Build the project and copy the plugin DLL into the appropriate directory:

    cmake --build ./build
    mkdir ./FlyWithLua/64
    cp ./build/lin.xpl ./FlyWithLua/64/
    

On OS X:

  1. Install XCode, Git, CMake (Homebrew can be convenient for this).

  2. Checkout and configure the project:

    git clone https://github.com/X-Friese/FlyWithLua.git
    cd FlyWithLua
    cmake -S ./src -B ./build -DCMAKE_BUILD_TYPE=RelWithDebInfo
    
  3. Build the project and copy the plugin DLL into the appropriate directory:

    cmake --build ./build
    mkdir ./FlyWithLua/64
    cp ./build/mac.xpl ./FlyWithLua/64/
    

Additional tips

How to cross-compile FlyWithLua on Ubuntu for Windows and OS X

Note: this is documented just in case, but generally is not recommended. Using native builds and/or GitHub Actions workflow is more convenient and less prone to errors and bugs.

Install cross-compiling toolchains:

# Install Windows cross-compiling toolchain (MinGW).
sudo apt-get install -y --no-install-recommends mingw-w64 g++-mingw-w64 && apt-get clean

# Install OS X cross-compiling toolchain (clang).
apt-get install -y --no-install-recommends clang curl && apt-get clean
#Build arguments
OSXCROSS_REPO="tpoechtrager/osxcross"
OSXCROSS_REVISION="f4ba4facae996b3b14d89eb62c0384564f7368b5"
DARWIN_SDK_VERSION="10.11"
DARWIN_SDK_URL="https://github.com/apriorit/osxcross-sdks/raw/master/MacOSX10.11.sdk.tar.xz"
CROSSBUILD=1

mkdir -p "/tmp/osxcross" \
 && cd "/tmp/osxcross" \
 && curl -sSLo osxcross.tar.gz "https://codeload.github.com/${OSXCROSS_REPO}/tar.gz/${OSXCROSS_REVISION}" \
 && tar --strip=1 -xzf osxcross.tar.gz \
 && rm -f osxcross.tar.gz \
 && curl -sLo tarballs/MacOSX${DARWIN_SDK_VERSION}.sdk.tar.xz \
             "${DARWIN_SDK_URL}" \
 && UNATTENDED=1 JOBS=4 SDK_VERSION=${DARWIN_SDK_VERSION} ./build.sh \
 && mv target /usr/osxcross \
 && mv tools /usr/osxcross/ \
 && rm -rf "/usr/osxcross/SDK/MacOSX${DARWIN_SDK_VERSION}.sdk/usr/share/man"

export PATH="$PATH:/usr/osxcross/bin"

Build FlyWithLua:

git clone https://github.com/X-Friese/FlyWithLua.git
cd FlyWithLua

# For Windows:
cmake -S ./src -B ./build-win -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_TOOLCHAIN_FILE=src/Toolchain-mingw-w64-x86-64.cmake
cmake --build ./build-win

# For OS X:
cmake -S ./src -B ./build-mac -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_TOOLCHAIN_FILE=src/Toolchain-ubuntu-osxcross-10.11.cmake -DCMAKE_FIND_ROOT_PATH=/usr/osxcross/SDK/MacOSX10.11.sdk/
cmake --build ./build-mac
How to create Code Blocks Project From CmakeLists.txt File
  • First you will need to install MinGW-64, Cmake, CodeBlocks and Git.
  • Create a CodeBlocks Projects folder like this.
  • mkdir CodeBlocksProjects
  • cd D:\CodeBlocksProjects
  • git clone https://github.com/X-Friese/FlyWithLua.git
  • cd FlyWithLua/src
  • mkdir build
  • cd build
  • cmake -G "CodeBlocks - MinGW Makefiles" ..
  • Open CodeBlocks and use "Open an existing project" browsing to "FlyWithLua/src/build/FlyWithLua.cbp" and click on the Open button.

At that point you should be able to build FlwWithLua.

How To Build Using QT Creator From the CmakeLists.txt File
  • Create a QT Creator Projects folder like this.
    • mkdir QTCreatorProjects
    • cd D:\QTCreatorProjects
    • git clone https://github.com/X-Friese/FlyWithLua.git
  • Using QT Creator use "File" > "Open File or Project" and browse to "FlyWithLua/src/CMakeLists.txt" then click on the "Open" button.

At that point you should be able to build FlyWithLua.




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
JamesWilko/Payday-2-BLT: Payday 2 Better Lua injecTor发布时间:2022-08-16
下一篇:
hchunhui/librime-lua: Extending RIME with Lua scripts发布时间:2022-08-16
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap