-
Notifications
You must be signed in to change notification settings - Fork 7.7k
[Libb64] Add new port #19447
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
Merged
Merged
[Libb64] Add new port #19447
Changes from 4 commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
816b26a
Added libb64 port
9cvele3 8465fad
baseline.json updated
9cvele3 0e32228
windows build fix. cmakelists copied to source tree
9cvele3 3b49b26
libb64.json added
9cvele3 394a432
PR comment, libb64 renamed to b64
9cvele3 6a2b76f
Update version database
9cvele3 92a4756
Update ports/b64/vcpkg.json
9cvele3 e232fe4
Update ports/b64/portfile.cmake
9cvele3 0d06c4a
Update ports/b64/portfile.cmake
9cvele3 d14a468
Update ports/b64/portfile.cmake
9cvele3 7c13e79
Update ports/b64/portfile.cmake
9cvele3 83026aa
Update ports/b64/portfile.cmake
9cvele3 2a846a5
fixes
9cvele3 975e69b
update version database
9cvele3 13b86c1
set -> add_compile_definitions
7bd655b
linux fix
9cvele3 81e93e2
updated database
9cvele3 c46e30d
correctly handling static and dynamic libs
9cvele3 24f372e
update database versions
9cvele3 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 hidden or 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,17 @@ | ||
| cmake_minimum_required(VERSION 3.20) | ||
| project(libb64) | ||
|
|
||
| set(SOURCE_FILES src/cdecode.c src/cencode.c) | ||
| set(HEADER_FILES include/b64/cdecode.h include/b64/cencode.h) | ||
|
|
||
| add_library(b64 STATIC ${SOURCE_FILES} ${HEADER_FILES}) | ||
| target_include_directories(b64 PRIVATE include) | ||
|
|
||
| set_target_properties(b64 PROPERTIES PUBLIC_HEADER "include/b64/cdecode.h;include/b64/cencode.h;include/b64/decode.h;include/b64/encode.h") | ||
|
|
||
| install(TARGETS b64 | ||
| LIBRARY DESTINATION lib | ||
| PUBLIC_HEADER DESTINATION include/b64 | ||
| ) | ||
|
|
||
|
9cvele3 marked this conversation as resolved.
Outdated
|
||
|
|
||
This file contains hidden or 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 @@ | ||
| Source: libb64 | ||
|
9cvele3 marked this conversation as resolved.
Outdated
|
||
| Version: 2.0.0.1 | ||
| Homepage: https://github.com/libb64/libb64 | ||
| Description: libb64 is a library of ANSI C routines for fast encoding/decoding data into and from a base64-encoded format. | ||
This file contains hidden or 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,25 @@ | ||
| vcpkg_from_github( | ||
| OUT_SOURCE_PATH SOURCE_PATH | ||
| REPO libb64/libb64 | ||
| REF v2.0.0.1 | ||
| SHA512 72c2fd4c81575b505f4851cd3820b6a2d8e78cd031a1ed138ffe5667ca711558f43b515428971966f7a73ace7c9951f1f0b39c362a59fe4691958875775cce23 | ||
| HEAD_REF master | ||
| PATCHES "windows-fix.patch" | ||
| ) | ||
|
|
||
| file(COPY ports/libb64/CMakeLists.txt DESTINATION ${SOURCE_PATH}/) | ||
|
|
||
| vcpkg_configure_cmake( | ||
| SOURCE_PATH ${SOURCE_PATH} | ||
| ) | ||
|
|
||
| vcpkg_install_cmake() | ||
|
|
||
| file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) | ||
|
|
||
| #vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/${PORT}) | ||
|
|
||
| vcpkg_copy_pdbs() | ||
|
|
||
| # handle copyright | ||
| file(INSTALL ${SOURCE_PATH}/LICENSE.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) |
This file contains hidden or 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,37 @@ | ||
| diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
| new file mode 100644 | ||
| index 0000000..baabe4f | ||
| --- /dev/null | ||
| +++ b/CMakeLists.txt | ||
| @@ -0,0 +1,15 @@ | ||
| +cmake_minimum_required(VERSION 3.20) | ||
| +project(libb64) | ||
| + | ||
| +set(SOURCE_FILES src/cdecode.c src/cencode.c) | ||
| +set(HEADER_FILES include/b64/cdecode.h include/b64/cencode.h) | ||
| + | ||
| +add_library(b64 STATIC ${SOURCE_FILES} ${HEADER_FILES}) | ||
| +target_include_directories(b64 PRIVATE include) | ||
| + | ||
| +set_target_properties(b64 PROPERTIES PUBLIC_HEADER "include/b64/cdecode.h;include/b64/cencode.h;include/b64/decode.h;include/b64/encode.h") | ||
| + | ||
| +install(TARGETS b64 | ||
| + LIBRARY DESTINATION lib | ||
| + PUBLIC_HEADER DESTINATION include/b64 | ||
| +) | ||
| + | ||
|
|
||
| diff --git a/include/b64/ccommon.h b/include/b64/ccommon.h | ||
| index 2b614df..28a9936 100644 | ||
| --- a/include/b64/ccommon.h | ||
| +++ b/include/b64/ccommon.h | ||
| @@ -14,7 +14,7 @@ For details, see http://sourceforge.net/projects/libb64 | ||
| #ifndef HAVE_SIZE_T | ||
| #ifdef _WIN32 | ||
| #include <crtdefs.h> | ||
| - #elseif defined (__unix__) || (defined (__APPLE__) && defined (__MACH__)) | ||
| + #elif defined (__unix__) || (defined (__APPLE__) && defined (__MACH__)) | ||
| #include <stdlib.h> | ||
| #else | ||
| typedef unsigned long size_t; | ||
|
|
This file contains hidden or 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
This file contains hidden or 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,9 @@ | ||
| { | ||
| "versions": [ | ||
| { | ||
| "git-tree": "4d76f006dba0db9a73b4eed985bc7966c42b1d2e", | ||
| "version-string": "2.0.0.1", | ||
| "port-version": 0 | ||
| } | ||
| ] | ||
| } |
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.
Uh oh!
There was an error while loading. Please reload this page.