-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Add asfernandes-cloop/0.0.0 #8951
Closed
friendlyanon
wants to merge
1
commit into
conan-io:master
from
friendlyanon:package/asfernandes-cloop
Closed
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
cmake_minimum_required(VERSION 3.1) | ||
|
||
project(cloop CXX) | ||
|
||
include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") | ||
conan_basic_setup(TARGETS) | ||
|
||
# ---- cloop executable ---- | ||
|
||
add_executable( | ||
cloop | ||
src/cloop/Expr.cpp | ||
src/cloop/Generator.cpp | ||
src/cloop/Lexer.cpp | ||
src/cloop/Main.cpp | ||
src/cloop/Parser.cpp | ||
src/cloop/Expr.h | ||
src/cloop/Generator.h | ||
src/cloop/Lexer.h | ||
src/cloop/Parser.h | ||
) | ||
|
||
# ---- Install rules ---- | ||
|
||
include(GNUInstallDirs) | ||
install(TARGETS cloop RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
sources: | ||
"0.0.0": | ||
sha256: "9f1415b08b5ac287656e08d2abbc78be99ba53f52713b5979aba312609bd5baf" | ||
url: https://github.com/asfernandes/cloop/archive/c5bd2516985660264a0ea72ade89f95a4bef3fd1.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import functools | ||
import os | ||
|
||
from conans import CMake, ConanFile, tools | ||
|
||
required_conan_version = ">=1.43.0" | ||
|
||
|
||
class CloopConan(ConanFile): | ||
name = "asfernandes-cloop" | ||
url = "https://github.com/conan-io/conan-center-index" | ||
homepage = "https://github.com/asfernandes/cloop" | ||
description = "Cross Language Object Oriented Programming" | ||
topics = ("parser", "idl") | ||
license = "???" | ||
settings = ("os", "arch", "compiler", "build_type") | ||
options = { | ||
"fPIC": [True, False], | ||
} | ||
default_options = { | ||
"fPIC": True, | ||
} | ||
generators = ("cmake",) | ||
# FIXME: remove the CML once https://github.com/asfernandes/cloop/pull/7 is | ||
# merged | ||
exports_sources = ("CMakeLists.txt", "idpl.txt") | ||
no_copy_source = True | ||
|
||
def config_options(self): | ||
if self.settings.os == "Windows": | ||
del self.options.fPIC | ||
|
||
def source(self): | ||
tools.get(**self.conan_data["sources"][self.version], strip_root=True) | ||
|
||
@functools.lru_cache(1) | ||
def _configure_cmake(self): | ||
cmake = CMake(self) | ||
cmake.configure() | ||
return cmake | ||
|
||
def build(self): | ||
self._configure_cmake().build() | ||
|
||
def package(self): | ||
self.copy("idpl.txt", "licenses") | ||
self._configure_cmake().install() | ||
|
||
def package_info(self): | ||
bindir = os.path.join(self.package_folder, "bin") | ||
self.output.info(f"Appending PATH environment variable: {bindir}") | ||
self.env_info.PATH.append(bindir) |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import os | ||
|
||
from conans import ConanFile, tools | ||
|
||
|
||
class TestPackageConan(ConanFile): | ||
settings = ("os", "arch", "compiler", "build_type") | ||
|
||
def test(self): | ||
if not tools.cross_building(self): | ||
idl = os.path.join(self.source_folder, "idl.idl") | ||
self.run(f"cloop {idl} json idl.json", run_environment=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
interface Disposable | ||
{ | ||
void dispose(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
versions: | ||
"0.0.0": | ||
folder: all |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This project uses the IDPL. This license does not have a SPDX identifier. What should it be named here?
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.
@uilianries I think we had some format for custom licenses not listed in SPDX, do you remember?
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.
Amazing, we are using Unlicensed when there is no license or is using Public Domain. But here is a different case, we just don't have a short name. IDPL is very close to Interbase-1.0, only the last paragraph is different. I would suggest using
Developer's Public License Version 1.0
for now and adding a # TODO for later. I see the developer involved is Brazilian (whata luck), I'll send an email asking him about the 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.
@uilianries found it: https://github.com/conan-io/conan-center-index/pull/4928/files#r596208293
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.
Thank you @SSE4! I just the email now and pointed this thread.
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.
Thanks for looking into this. FirebirdSQL is also licensed with IDPL, so it will prove to be useful for that.