Skip to content

Commit

Permalink
[73_6] Use libgit2-dev on ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
da-liii authored Jan 9, 2024
1 parent 7516af4 commit a91209c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cd_research_on_ubuntu_22_04.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
sudo DEBIAN_FRONTEND=noninteractive apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y gcc \
qt6-base-dev libqt6svg6-dev qt6-image-formats-plugins fonts-noto-cjk \
libcurl4-openssl-dev libfreetype-dev fakeroot debhelper
libcurl4-openssl-dev libfreetype-dev fakeroot debhelper libgit2-dev
- uses: actions/checkout@v3
with:
fetch-depth: 1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-xmake-ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ jobs:
sudo DEBIAN_FRONTEND=noninteractive apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y gcc \
fonts-noto-cjk libcurl4-openssl-dev libfreetype-dev \
${{matrix.qt_pkg}}
${{matrix.qt_pkg}} libgit2-dev
- uses: actions/checkout@v3
with:
fetch-depth: 1
Expand Down
9 changes: 9 additions & 0 deletions xmake-requires.lock
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
{
["linux|x86_64"] = {
["apt::libcurl4-openssl-dev#31fecfc4"] = {
version = "latest"
},
["apt::libfreetype-dev#31fecfc4"] = {
version = "latest"
},
["apt::libgit2-dev#31fecfc4"] = {
version = "latest"
},
["apt::libjpeg62-turbo-dev#31fecfc4"] = {
version = "latest"
},
Expand Down
8 changes: 6 additions & 2 deletions xmake/packages.lua
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ function add_requires_of_mogan()
add_requireconfs("lolly.cpr", {version = CPR_VERSION, system = false, override=true})

-- package: libcurl
if is_plat("linux") and using_apt() and (not linuxos.name() == "uos") then
if is_plat("linux") and using_apt() then
if linuxos.name() == "uos" then
add_requireconfs("lolly.cpr.libcurl", {version = CURL_VERSION, system = false, override=true})
else
Expand All @@ -90,6 +90,7 @@ function add_requires_of_mogan()
end
else
add_requireconfs("lolly.cpr.libcurl", {version = CURL_VERSION, system = false, override=true})
add_requireconfs("lolly.cpr.libcurl.cmake", {version = CMAKE_VERSION, system = false, override=true})
end

-- package: fontconfig
Expand All @@ -105,6 +106,7 @@ function add_requires_of_mogan()
set_configvar("PDFHUMMUS_VERSION", PDFHUMMUS_VERSION)
if not is_plat("wasm") then
add_requires("pdfhummus "..PDFHUMMUS_VERSION, {system=false,configs={libpng=true,libjpeg=true}})
add_requireconfs("pdfhummus.cmake", {version = CMAKE_VERSION, system = false, override=true})
end

-- package: libpng
Expand Down Expand Up @@ -145,7 +147,9 @@ function add_requires_of_mogan()

-- package: libgit2
set_configvar("LIBGIT2_VERSION", LIBGIT2_VERSION)
if not is_plat("wasm") then
if is_plat ("linux") and using_apt() and (not (linuxos.name() == "uos")) then
add_requires("apt::libgit2-dev", {alias="libgit2"})
elseif not is_plat("wasm") then
add_requires("libgit2 "..LIBGIT2_VERSION, {system=false})
add_requireconfs("libgit2.cmake", {version = CMAKE_VERSION, system = false, override=true})
end
Expand Down

0 comments on commit a91209c

Please sign in to comment.