Skip to content

Commit

Permalink
[51_1] New glue: freetype-version
Browse files Browse the repository at this point in the history
  • Loading branch information
da-liii authored Dec 7, 2023
1 parent f7066a7 commit 7746ccd
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
5 changes: 5 additions & 0 deletions src/Scheme/Glue/glue_font.lua
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,11 @@ function main()
"url"
}
},
{
scm_name = "freetype-version",
cpp_name = "freetype_version",
ret_type = "string",
},
}
}
end
7 changes: 7 additions & 0 deletions src/Scheme/L5/init_glue_l5.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,13 @@ bench_print_all () {
#include "Freetype/tt_file.hpp"
#include "Metafont/tex_files.hpp"
#include "font.hpp"
#include <freetype/freetype.h>

string
freetype_version () {
return as_string (FREETYPE_MAJOR) * "." * as_string (FREETYPE_MINOR) * "." *
as_string (FREETYPE_PATCH);
}

#include "glue_basic.cpp"
#include "glue_editor.cpp"
Expand Down
3 changes: 1 addition & 2 deletions xmake/packages.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ local TBOX_VERSION = "1.7.5"
local CPR_VERSION = "1.10.5"
local CURL_VERSION = "8.4.0"
local PDFHUMMUS_VERSION = "4.6.1"
local FREETYPE_VERSION = "2.12.1"

-- https://xmake.io/#/manual/package_dependencies?id=inherit-package-configuration
package("lolly")
Expand Down Expand Up @@ -51,8 +52,6 @@ package_end()


function add_requires_of_mogan()
local FREETYPE_VERSION = "2.12.1"

if is_plat("linux") and (linuxos.name() == "ubuntu" or linuxos.name() == "uos") then
-- config package name for freetype on UOS
if linuxos.name() == "uos" then
Expand Down

0 comments on commit 7746ccd

Please sign in to comment.