Skip to content

Commit

Permalink
[libmount] Update to 2.39 and fix (microsoft#35738)
Browse files Browse the repository at this point in the history
  • Loading branch information
dg0yt authored and Osyotr committed Jan 23, 2024
1 parent 0c610f2 commit 5c9f580
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 20 deletions.
37 changes: 23 additions & 14 deletions ports/libmount/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
set(VERSION_MAJOR 2)
set(VERSION_MINOR 38)
set(VERSION ${VERSION_MAJOR}.${VERSION_MINOR})

vcpkg_download_distfile(ARCHIVE
URLS "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v${VERSION_MAJOR}.${VERSION_MINOR}/util-linux-${VERSION}.tar.xz"
URLS "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v${VERSION}/util-linux-${VERSION}.tar.xz"
FILENAME "util-linux-${VERSION}.tar.xz"
SHA512 d0f7888f457592067938e216695871ce6475a45d83a092cc3fd72b8cf8fca145ca5f3a99122f1744ef60b4f773055cf4e178dc6c59cd30837172aee0b5597e8c
SHA512 3d59a0f114c06be19ef7f86fca37ba5b9073823d011b3fc37997ddb00124b4505ea32903b78798a64dffbccf0ba645a692678ee845cc65a5b321824448a82a94
)

vcpkg_extract_source_archive(
Expand All @@ -16,26 +12,39 @@ vcpkg_extract_source_archive(

set(ENV{GTKDOCIZE} true)

vcpkg_list(SET options)
if("nls" IN_LIST FEATURES)
vcpkg_list(APPEND options "--enable-nls")
else()
set(ENV{AUTOPOINT} true) # true, the program
vcpkg_list(APPEND options "--disable-nls")
endif()

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
${options}
--disable-asciidoc
--disable-all-programs
--disable-dependency-tracking
--enable-libmount
--enable-libblkid
"--mandir=${CURRENT_PACKAGES_DIR}/share/man"
)

vcpkg_install_make()
vcpkg_fixup_pkgconfig()

if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/sbin" "${CURRENT_PACKAGES_DIR}/debug/sbin")
endif()

file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/tools") # empty folder
file(REMOVE_RECURSE
"${CURRENT_PACKAGES_DIR}/debug/bin"
"${CURRENT_PACKAGES_DIR}/debug/sbin"
"${CURRENT_PACKAGES_DIR}/debug/share"
"${CURRENT_PACKAGES_DIR}/bin"
"${CURRENT_PACKAGES_DIR}/sbin"
"${CURRENT_PACKAGES_DIR}/share"
"${CURRENT_PACKAGES_DIR}/tools"
)

file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/README.licensing" "${SOURCE_PATH}/COPYING")
22 changes: 18 additions & 4 deletions ports/libmount/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,23 @@
{
"name": "libmount",
"version": "2.38",
"port-version": 2,
"version": "2.39",
"description": "Block device identification library from util-linux",
"homepage": "https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git/about/",
"license": "GPL-2.0-only",
"supports": "linux"
"license": null,
"supports": "linux",
"features": {
"nls": {
"description": "Enable native language support",
"dependencies": [
{
"name": "gettext",
"host": true,
"features": [
"tools"
]
},
"gettext-libintl"
]
}
}
}
4 changes: 2 additions & 2 deletions versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4553,8 +4553,8 @@
"port-version": 0
},
"libmount": {
"baseline": "2.38",
"port-version": 2
"baseline": "2.39",
"port-version": 0
},
"libmpeg2": {
"baseline": "0.5.1",
Expand Down
5 changes: 5 additions & 0 deletions versions/l-/libmount.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "5fbc2733330a3bac410e90c460db96f54e39e0a5",
"version": "2.39",
"port-version": 0
},
{
"git-tree": "747604a5c97736ced9e0ef3b2963c2c949bdc655",
"version": "2.38",
Expand Down

0 comments on commit 5c9f580

Please sign in to comment.