Skip to content

Commit

Permalink
Merge branch 'master' into more-lief
Browse files Browse the repository at this point in the history
* master: (103 commits)
  [lmdb] don't use msvc parameters with non-msvc compiler (microsoft#23653)
  Fix <version> of Python in vcpkgTools.xml (microsoft#23751)
  [sciter] escape quotes (microsoft#23752)
  [fuzzylite] Fix Linux build (microsoft#23658)
  [cpp-redis] Fix ‘sleep_for’ is not a member of ‘std::this_thread’ (microsoft#23762)
  [nlohmann-json] Fix usage text (microsoft#23749)
  [fontconfig] Do not create symlinks (microsoft#23735) (microsoft#23736)
  [winsparkle] Fix header file and debug path (microsoft#23739)
  [arb] Support dynamic build (microsoft#23743)
  [aws-sdk-cpp] update to 1.9.220 (microsoft#23729)
  Fix the VS2022 'unstable' queues. (microsoft#23742)
  [xmlsec] Bump to 1.2.33 (microsoft#23733)
  [unicorn] update to latest version v1.0.3 (microsoft#23745)
  [libpq] Update version to 14.1 2 (microsoft#22516)
  [libnoise] Export CMake files (microsoft#23682)
  [vcpk-ci] Trigger some test ports from vcpkg.cmake changes (microsoft#23430)
  [nlohmann-json] Add option to control implicit conversions behaviour (microsoft#22409)
  [libjuice] Update to 0.9.8 (microsoft#23153)
  [libgeotiff] Update to 1.7.1 (microsoft#23446)
  [minizip-ng] Updated minizip version and fixed windows build for previous version (microsoft#23684)
  ...
  • Loading branch information
ekilmer committed Mar 26, 2022
2 parents 6953c65 + a95ee82 commit 558f302
Show file tree
Hide file tree
Showing 516 changed files with 5,409 additions and 2,348 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/other-type-of-bug-report.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Repro code when
**Expected behavior**
A clear and concise description of what you expected to happen.

**Failure logs**
**Failure logs**
-(please attached failure logs)

**Additional context**
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/report-package-build-failure.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ assignees: ''
Steps to reproduce the behavior:
`./vcpkg install xxxx`

**Failure logs**
**Failure logs**
-Cut and paste the appropriate build messages from the console output.
-Please attach any additional failure logs mentioned in the console output.

Expand Down
8 changes: 4 additions & 4 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
**Describe the pull request**

- #### What does your PR fix?
- #### What does your PR fix?
Fixes #...

- #### Which triplets are supported/not supported? Have you updated the [CI baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt)?
- #### Which triplets are supported/not supported? Have you updated the [CI baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt)?
<all / linux, windows, ...>, <Yes/No>

- #### Does your PR follow the [maintainer guide](https://github.com/microsoft/vcpkg/blob/master/docs/maintainers/maintainer-guide.md)?
- #### Does your PR follow the [maintainer guide](https://github.com/microsoft/vcpkg/blob/master/docs/maintainers/maintainer-guide.md)?
`Your answer`

- #### If you have added/updated a port: Have you run `./vcpkg x-add-version --all` and committed the result?
- #### If you have added/updated a port: Have you run `./vcpkg x-add-version --all` and committed the result?
<Yes / I am still working on this PR>

**If you are still working on the PR, open it as a Draft: https://github.blog/2019-02-14-introducing-draft-pull-requests/**
10 changes: 5 additions & 5 deletions .github/workflows/trustedPR.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,18 @@ jobs:
steps:
- name: 'Download artifact'
uses: actions/github-script@v3.1.0
uses: actions/github-script@v6
with:
script: |
var artifacts = await github.actions.listWorkflowRunArtifacts({
var artifacts = await github.rest.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: ${{github.event.workflow_run.id }},
});
var matchArtifact = artifacts.data.artifacts.filter((artifact) => {
return artifact.name == "pr"
})[0];
var download = await github.actions.downloadArtifact({
var download = await github.rest.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: matchArtifact.id,
Expand All @@ -38,7 +38,7 @@ jobs:
fs.writeFileSync('${{github.workspace}}/pr.zip', Buffer.from(download.data));
- run: unzip pr.zip

- uses: actions/github-script@v4
- uses: actions/github-script@v6
with:
script: |
const { promises: fs } = require('fs')
Expand All @@ -55,4 +55,4 @@ jobs:
if (body !== "") {
req.body = body;
}
await github.pulls.createReview(req);
await github.rest.pulls.createReview(req);
6 changes: 3 additions & 3 deletions .github/workflows/untrustedPR.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
# fetch-depth 50 tries to ensure we capture the whole history of the branch
fetch-depth: 50
Expand Down Expand Up @@ -51,7 +51,7 @@ jobs:
git diff > .github-pr.x-add-version.diff
git reset HEAD~ --mixed
- uses: actions/github-script@v4
- uses: actions/github-script@v6
with:
script: |
const { promises: fs } = require('fs')
Expand Down Expand Up @@ -126,7 +126,7 @@ jobs:
console.log(output);
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: pr
path: pr/
5 changes: 5 additions & 0 deletions docs/maintainers/vcpkg_extract_source_archive.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ The latter is suggested to use for all future `vcpkg_extract_source_archive`s.
vcpkg_extract_source_archive(<out-var>
ARCHIVE <path>
[NO_REMOVE_ONE_LEVEL]
[SKIP_PATCH_CHECK]
[PATCHES <patch>...]
[SOURCE_BASE <base>]
[BASE_DIRECTORY <relative-path> | WORKING_DIRECTORY <absolute-path>]
Expand Down Expand Up @@ -59,6 +60,10 @@ prevent `vcpkg_extract_source_archive` from performing this transformation.

If the source needs to be patched in some way, the `PATCHES` argument
allows one to do this, just like other `vcpkg_from_*` functions.
Additionally, the `SKIP_PATCH_CHECK` is provided for `--head` mode -
this allows patches to fail to apply silently.
This argument should _only_ be used when installing a `--head` library,
since otherwise we want a patch failing to appply to be a hard error.

`vcpkg_extract_source_archive` extracts the files to
`${CURRENT_BUILDTREES_DIR}/<base-directory>/<source-base>-<hash>.clean`.
Expand Down
5 changes: 5 additions & 0 deletions ports/7zip/7zip-config.cmake.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
@PACKAGE_INIT@

include("${CMAKE_CURRENT_LIST_DIR}/7zip-targets.cmake")

check_required_components(7zip)
110 changes: 81 additions & 29 deletions ports/7zip/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

cmake_minimum_required(VERSION 3.19)

project(7zip LANGUAGES C CXX)
Expand Down Expand Up @@ -62,6 +61,7 @@ target_sources(7zip PRIVATE
CPP/7zip/Compress/ZlibEncoder.cpp
CPP/7zip/Compress/ZDecoder.cpp
CPP/7zip/Compress/CodecExports.cpp

CPP/7zip/Crypto/7zAes.cpp
CPP/7zip/Crypto/7zAesRegister.cpp
CPP/7zip/Crypto/HmacSha1.cpp
Expand Down Expand Up @@ -95,14 +95,13 @@ target_sources(7zip PRIVATE
C/Lzma2Dec.c
C/Lzma2DecMt.c
C/Lzma2Enc.c
C/LzmaDec.c
C/LzmaEnc.c
C/LzmaLib.c
C/MtCoder.c
C/MtDec.c
C/Ppmd7.c
C/Ppmd7aDec.c
C/Ppmd7Dec.c
C/Ppmd7aDec.c
C/Ppmd7Enc.c
C/Ppmd8.c
C/Ppmd8Dec.c
Expand Down Expand Up @@ -130,7 +129,9 @@ target_sources(7zip PRIVATE
CPP/Common/MyWindows.cpp
CPP/Common/MyXml.cpp
CPP/Common/NewHandler.cpp
CPP/Common/Sha1Prepare.cpp
CPP/Common/Sha1Reg.cpp
CPP/Common/Sha256Prepare.cpp
CPP/Common/Sha256Reg.cpp
CPP/Common/StringConvert.cpp
CPP/Common/StringToInt.cpp
Expand Down Expand Up @@ -174,8 +175,8 @@ target_sources(7zip PRIVATE
CPP/7zip/Archive/ApmHandler.cpp
CPP/7zip/Archive/ArHandler.cpp
CPP/7zip/Archive/ArjHandler.cpp
CPP/7zip/Archive/Bz2Handler.cpp
CPP/7zip/Archive/Base64Handler.cpp
CPP/7zip/Archive/Bz2Handler.cpp
CPP/7zip/Archive/ComHandler.cpp
CPP/7zip/Archive/CpioHandler.cpp
CPP/7zip/Archive/CramfsHandler.cpp
Expand Down Expand Up @@ -291,36 +292,40 @@ target_sources(7zip PRIVATE
C/Util/LzmaLib/LzmaLib.def
)

# 7zCrcOpt # AesOpt # Sha1Opt # Sha256Opt # XzCrc64Opt # LzFindOpt
set(WINDOWS_PRIVATE_HEADERS
Asm/x86/7zCrcOpt.asm
Asm/x86/AesOpt.asm
Asm/x86/Sha1Opt.asm
Asm/x86/Sha256Opt.asm
Asm/x86/XzCrc64Opt.asm
Asm/x86/LzFindOpt.asm
)
set(WINDOWS_PRIVATE_SOURCE_FILES
C/7zCrcOpt.c
C/AesOpt.c
C/Sha1Opt.c
C/Sha256Opt.c
C/XzCrc64Opt.c
C/LzFindOpt.c
)

# 7zCrcOpt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE ${WINDOWS_PRIVATE_HEADERS})
set_source_files_properties(${WINDOWS_PRIVATE_HEADERS} PROPERTIES LANGUAGE ASM_MASM)
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "arm")
#target_sources(7zip PRIVATE Asm/arm/7zCrcOpt.asm)
target_sources(7zip PRIVATE Asm/x86/7zCrcOpt.asm)
set_source_files_properties(Asm/x86/7zCrcOpt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE C/7zCrcOpt.c)
endif()
else()
target_sources(7zip PRIVATE C/7zCrcOpt.c)
endif()

# AesOpt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE Asm/x86/AesOpt.asm)
set_source_files_properties(Asm/x86/AesOpt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE ${WINDOWS_PRIVATE_SOURCE_FILES})
target_sources(7zip PRIVATE C/AesOpt.c)
endif()
else()
target_sources(7zip PRIVATE ${WINDOWS_PRIVATE_SOURCE_FILES})
target_sources(7zip PRIVATE C/AesOpt.c)
endif()

# LzFindOpt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE Asm/x86/LzFindOpt.asm)
set_source_files_properties(Asm/x86/LzFindOpt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE C/LzFindOpt.c)
endif()
else()
target_sources(7zip PRIVATE C/LzFindOpt.c)
endif()

# LzmaDecOpt
Expand All @@ -334,13 +339,49 @@ if((VCPKG_TARGET_IS_WINDOWS AND VCPKG_TARGET_ARCHITECTURE STREQUAL "x64") OR
elseif(VCPKG_TARGET_IS_LINUX AND VCPKG_TARGET_ARCHITECTURE STREQUAL "arm64")
target_sources(7zip PRIVATE Asm/arm64/LzmaDecOpt.S)
set_source_files_properties(Asm/x86/LzmaDecOpt.asm PROPERTIES LANGUAGE ASM)
endif()
endif()

get_source_file_property(defs C/LzmaDec.c COMPILE_DEFINITIONS)
list(APPEND defs "_LZMA_DEC_OPT")
set_source_files_properties(C/LzmaDec.c PROPERTIES COMPILE_DEFINITIONS "${defs}")
endif()

# Sha1Opt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE Asm/x86/Sha1Opt.asm)
set_source_files_properties(Asm/x86/Sha1Opt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE C/Sha1Opt.c)
endif()
else()
target_sources(7zip PRIVATE C/Sha1Opt.c)
endif()

# Sha256Opt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE Asm/x86/Sha256Opt.asm)
set_source_files_properties(Asm/x86/Sha256Opt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE C/Sha256Opt.c)
endif()
else()
target_sources(7zip PRIVATE C/Sha256Opt.c)
endif()

# XzCrc64Opt
if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86" OR VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
target_sources(7zip PRIVATE Asm/x86/XzCrc64Opt.asm)
set_source_files_properties(Asm/x86/XzCrc64Opt.asm PROPERTIES LANGUAGE ASM_MASM)
else()
target_sources(7zip PRIVATE C/XzCrc64Opt.c)
endif()
else()
target_sources(7zip PRIVATE C/XzCrc64Opt.c)
endif()

target_compile_definitions(7zip
PUBLIC
-D_REENTRANT
Expand Down Expand Up @@ -398,6 +439,17 @@ foreach(HEADER ${PUBLIC_HEADERS})
)
endforeach()

include(CMakePackageConfigHelpers)
configure_package_config_file(
"${CMAKE_CURRENT_SOURCE_DIR}/7zip-config.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/7zip-config.cmake"
INSTALL_DESTINATION "share/7zip"
)
install(
FILES "${CMAKE_CURRENT_BINARY_DIR}/7zip-config.cmake"
DESTINATION "share/7zip"
)

install(
EXPORT 7zip-targets
DESTINATION share/7zip
Expand Down
16 changes: 8 additions & 8 deletions ports/7zip/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
set(7ZIP_VERSION 21.07)
set(7ZIP_VERSION "2107")
vcpkg_download_distfile(ARCHIVE
URLS "https://www.7-zip.org/a/7z2107-src.7z"
FILENAME "7z2107-src.7z"
URLS "https://www.7-zip.org/a/7z${7ZIP_VERSION}-src.7z"
FILENAME "7z${7ZIP_VERSION}-src.7z"
SHA512 c13521a9829ac239a89015e1f5da27eeaa2469754e3f8ca32311d964ea9d0b40a17e4f8ccbd425d3e865aa768be345368f1c36f354d5710ac7cb2749dd6a3ab5
)

vcpkg_extract_source_archive_ex(
OUT_SOURCE_PATH SOURCE_PATH
ARCHIVE ${ARCHIVE}
REF ${7ZIP_VERSION}
vcpkg_extract_source_archive(
SOURCE_PATH
ARCHIVE "${ARCHIVE}"
NO_REMOVE_ONE_LEVEL
)

file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
file(COPY "${CMAKE_CURRENT_LIST_DIR}/7zip-config.cmake.in" DESTINATION "${SOURCE_PATH}")

vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
Expand Down
41 changes: 0 additions & 41 deletions ports/7zip/unRarLicense.txt

This file was deleted.

1 change: 1 addition & 0 deletions ports/7zip/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"name": "7zip",
"version-string": "21.07",
"port-version": 1,
"description": "Library for archiving file with a high compression ratio.",
"homepage": "https://www.7-zip.org",
"license": "LGPL-2.1-or-later",
Expand Down
2 changes: 0 additions & 2 deletions ports/arb/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO fredrik-johansson/arb
Expand Down
Loading

0 comments on commit 558f302

Please sign in to comment.