From 716a716e36335efe5a13b6f10f9d60ceb59499d0 Mon Sep 17 00:00:00 2001 From: Joel Verhagen Date: Tue, 16 Jan 2024 17:12:12 -0500 Subject: [PATCH] Move script and add NOTICES.md file --- {scripts => src/lua}/Invoke-LuaBuild.ps1 | 2 +- src/lua/NOTICES.md | 67 ++++++++++++++++++++++++ 2 files changed, 68 insertions(+), 1 deletion(-) rename {scripts => src/lua}/Invoke-LuaBuild.ps1 (98%) create mode 100644 src/lua/NOTICES.md diff --git a/scripts/Invoke-LuaBuild.ps1 b/src/lua/Invoke-LuaBuild.ps1 similarity index 98% rename from scripts/Invoke-LuaBuild.ps1 rename to src/lua/Invoke-LuaBuild.ps1 index 0ebcf9a7..f50fb09a 100644 --- a/scripts/Invoke-LuaBuild.ps1 +++ b/src/lua/Invoke-LuaBuild.ps1 @@ -1,7 +1,7 @@ [CmdletBinding()] param () -$repoDir = Resolve-Path (Join-Path $PSScriptRoot "..") +$repoDir = Resolve-Path (Join-Path $PSScriptRoot "../..") $compilerDir = Join-Path $repoDir "submodules/CSharp.lua/CSharp.lua.Launcher" $baseOutputDir = Join-Path $repoDir "src/lua" diff --git a/src/lua/NOTICES.md b/src/lua/NOTICES.md new file mode 100644 index 00000000..d4d61f2b --- /dev/null +++ b/src/lua/NOTICES.md @@ -0,0 +1,67 @@ +This directory contains source (either original or transpiled) of the following open source projects. + +The transpiled source is transpiled using the `Invoke-LuaBuild.ps1` script in this directory. Internally it uses my fork +of CSharp.lua to compile + +The `FactorioTools` and `FluteSharp` directories are transpiled Lua sources generated from C# in the +`../src/FactorioTools` directory and my [FluteSharp](https://github.com/joelverhagen/FluteSharp) project respectively. + +## CSharp.lua + +- Original repository: https://github.com/yanghuan/CSharp.lua +- Author: [yanghuan](https://github.com/yanghuan) (YANG Huan) +- My fork: https://github.com/joelverhagen/CSharp.lua +- Changes in my fork: + - [diff](https://github.com/yanghuan/CSharp.lua/compare/master...joelverhagen:CSharp.lua:lua-compat) + +### Original license +``` +Copyright 2017 YANG Huan (sy.yanghuan@gmail.com). + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +``` + +## DelaunatorSharp + +- Original repository: https://github.com/nol1fe/delaunator-sharp +- Author: [nol1fe](https://github.com/nol1fe) (Patryk Grech) +- My fork: https://github.com/joelverhagen/delaunator-sharp +- Changes in my fork: + - [diff](https://github.com/nol1fe/delaunator-sharp/compare/master...joelverhagen:delaunator-sharp:lua-compat) + - Refactor decrement and assign to separate statements. Workaround for [yanghuan/CSharp.lua#473](https://github.com/yanghuan/CSharp.lua/issues/473). + - Refactor LINQ usage to simple array implementation. Workaround for Factorio not supporting Lua coroutines. + +### Original license +``` +MIT License + +Copyright (c) 2019 Patryk Grech + +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. +``` \ No newline at end of file