-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Added Lua 5.3.5 recipe #545
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
@@ -0,0 +1,87 @@ | |||
cmake_minimum_required(VERSION 2.8.12) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where did you find this Cmake file? Did you try the port in vcpkg? Some definitions that I saw there in vcpkg are not here in this file. Unfortunately, the Lua's author don't want native cmake support.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I use the one from vcpkg instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, please. It's more maintained and contain extra features, as compiler definitions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@GavinNL ping
recipes/lua/all/conanfile.py
Outdated
from distutils.dir_util import copy_tree | ||
|
||
|
||
license = """================================================================================ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do not copy the license directly in the recipe. Extract it from src/lua.h. Take a look here to understand how to extract: https://docs.conan.io/en/latest/howtos/extract_licenses_from_headers.html
recipes/lua/all/conanfile.py
Outdated
""" | ||
|
||
class LuaConan(ConanFile): | ||
no_copy_source = True |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no_copy_source = True |
Use no_copy_source
only for header-only
recipes/lua/all/conanfile.py
Outdated
exports_sources = ["CMakeLists.txt"] | ||
|
||
_source_subfolder = "source_subfolder" | ||
_build_subfolder = "build_subfolder" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_build_subfolder = "build_subfolder" |
You are not using this.
@@ -0,0 +1,34 @@ | |||
From 3a53ea1f692251c052bf0b99cbc484c4f6641a8d Mon Sep 17 00:00:00 2001 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where did you find this patch?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Errr...that shouldn't be there...I copied the whole recipe from GLM I believe
recipes/lua/all/conanfile.py
Outdated
|
||
def package_info(self): | ||
self.cpp_info.libs = tools.collect_libs(self) | ||
self.cpp_info.includedirs.append("include/lua") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
self.cpp_info.includedirs.append("include/lua") | |
self.cpp_info.includedirs.append("include/lua") | |
if self.settings.os == "Linux": | |
self.cpp_info.system_libs = ["m"] |
Take a look in the makefile
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
Signed-off-by: Uilian Ries <uilianries@gmail.com>
conan-io#545 Add cpp build as option
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
- lua.hpp is no included when compile_as_cpp is turned on. - needed to modify the test_package CMakeLists file to include a preprocessor definition when compiling with compile_as_cpp turned on
Sorry, the build is only launched for Early Access Program users. You can request access writing in this issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove explicit COMPILE_AS_CPP from cmake and conanfile in test package
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Forget about, LGTM.
All green in build 6 (
|
All green in build 7 (
|
@SSE4 Will be really happy reviewing this PR, he loves Lua! 🙊 |
Library name and version: lua/5.3.5
Copied the recipe from sqlite and then modified.
Tested on Linux Mint 19.2 GCC7 using the following
CMakeLists.txt file copied with permission from https://github.com/helmesjo/conan-lua
conan-center hook activated.