jmcnamara / libxlsxwriter

A C library for creating Excel XLSX files.
https://libxlsxwriter.github.io
Other
1.49k stars 332 forks source link

[vcpkg] license #392

Closed Teles1 closed 1 year ago

Teles1 commented 1 year ago

I submitted a pull request and they recommended updating the license agreement in there in order to make it complete. I thought it was Free BSD but the header files mention something else. Perhaps could you submit a pull request to vcpkg updating it? Here is the PR I sent-> https://github.com/microsoft/vcpkg/pull/29401

FrankXie05 commented 1 year ago

@Teles1 I don't think the upstream licenses did anything wrong, they just mentioned all the licenses involved in the files they used. This is normal behavior. If you want to add Free BSD licenses, you can suggest that they separate all licenses. Take it out and perfect it. 🧐

Teles1 commented 1 year ago

@FrankXie05 Licenses are just a nightmare to deal with. That's way too much work for the creator. I'll leave the issue here none the less until the creator sees it.

FrankXie05 commented 1 year ago

For open source and sharing, the license is a must. It constrains others to use the open source library under the conditions of the license. Although this sounds contradictory, it is the fundamental guarantee for using the open source library. Even if it's a headache to hwo to add the license. 😣

jmcnamara commented 1 year ago

Folks I would prefer the license field to say FreeBSD or link to the license file.

I put a lot of work into clarifying the main license in the docs and the licences of all of the optional sub-components. I've also detailed how any of the sub-licensed components can be compiled in/out. The issue there, from a vcpkg point of view, is that adding those additional compilation options to compile out the embedded libraries and replace them with system libraries will make the compilation more error prone (in particular openssl).

But either way a license file of null feels sub-optimal.

Teles1 commented 1 year ago

Oh right. Fair enough. I tried putting in OpenBSD as the license in there in first place but can't merge it in hence the mixture of licenses. And I have to agree with @jmcnamara my nightmare when I was getting started with c++ was libraries with multiple dependencies and back then i didn't know how to put them together without having to compile every single one with MSVC.

jmcnamara commented 1 year ago

@Teles1 do you know what are the allowed licences in that field? The specific license for libxlsxwriter is: BSD 2-Clause "Simplified" License. https://spdx.org/licenses/BSD-2-Clause.html

jmcnamara commented 1 year ago

I'll answer my own question by reading the docs :-)

The license of the port. This is an SPDX license expression, or null for proprietary licenses and other licenses for which one should "just read the copyright file" (e.g., Qt).

So, the license field should be the SPDX identifier BSD-2-Clause or if you feel that isn't complete, I think it is, then set it to null.

Teles1 commented 1 year ago

Let's wait for @FrankXie05 He's the specialist in this case lol. But I did try BSD and then Frank mentioned this. Thank you for spending some of your time on this.

Teles1 commented 1 year ago

To be fair I think there is something else wrong with vcpkg + libxlswriter. I just tried using it and I can't import it on my cmake project even after the fact that I installed it. It can't find it. Works fine on Visual Studio tho.

I tried find_package(xlsxwriter CONFIG REQUIRED) and find_package(libxlsxwriterCONFIG REQUIRED)

Teles1 commented 1 year ago

Yah, it works fine standalone cmake + add_subdirectory. `add_subdirectory(libxlsxwriter)

target_link_libraries(excel PRIVATE xlsxwriter)`

Something to do with vcpkg export methodology that I am not familiar with.

FrankXie05 commented 1 year ago

@Teles1 do you know what are the allowed licences in that field? The specific license for libxlsxwriter is: BSD 2-Clause "Simplified" License. https://spdx.org/licenses/BSD-2-Clause.html

@Teles1 We respect the choice of the upstream, since the author stated that the specific license is BSD-2-Clause, we also allow the license to be added to port libxlsxwriter. I will complete this task today. :)

To be fair I think there is something else wrong with vcpkg + libxlswriter. I just tried using it and I can't import it on my cmake project even after the fact that I installed it. It can't find it. Works fine on Visual Studio tho.

I tried find_package(xlsxwriter CONFIG REQUIRED) and find_package(libxlsxwriterCONFIG REQUIRED)

Maybe you missed the CMAKE_TOOLCHAIN_FILE.

Teles1 commented 1 year ago

I'm using vcpkg for other libraries and couldn't get it to work. It may just be me being dumb too. Thank you sir for your great work

On Sun, Feb 5, 2023, 9:24 p.m. Frank @.***> wrote:

@Teles1 https://github.com/Teles1 do you know what are the allowed licences in that field? The specific license for libxlsxwriter is: BSD 2-Clause "Simplified" License. https://spdx.org/licenses/BSD-2-Clause.html

@Teles1 https://github.com/Teles1 We respect the choice of the upstream, since the author stated that the specific license is BSD-2-Clause, we also allow the license to be added to port libxlsxwriter. I will complete this task today. :)

To be fair I think there is something else wrong with vcpkg + libxlswriter. I just tried using it and I can't import it on my cmake project even after the fact that I installed it. It can't find it. Works fine on Visual Studio tho.

I tried find_package(xlsxwriter CONFIG REQUIRED) and find_package(libxlsxwriterCONFIG REQUIRED)

Maybe you missed the CMAKE_TOOLCHAIN_FILE.

— Reply to this email directly, view it on GitHub https://github.com/jmcnamara/libxlsxwriter/issues/392#issuecomment-1418405398, or unsubscribe https://github.com/notifications/unsubscribe-auth/AP5QR4DLWEMRMK23AZBAJGLWWBOETANCNFSM6AAAAAAUPX6QQQ . You are receiving this because you were mentioned.Message ID: @.***>

FrankXie05 commented 1 year ago

@Teles1 For the use of most of the ports provided by vcpkg. Just add two lines of code. :) The first add find_package(), and second link your project: target_link_libraries(project_name PRIVATE xlsxwriter).