Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[submodule "harfbuzz-sys/harfbuzz"]
path = harfbuzz-sys/harfbuzz
url = https://github.com/harfbuzz/harfbuzz
[submodule "harfbuzz-sys/freetype-sys"]
path = harfbuzz-sys/freetype-sys
url = https://github.com/PistonDevelopers/freetype-sys
Comment on lines +4 to +6
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this change belongs here. Can we simply add the configuration define for now?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

android builds fail without this

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

harfbuzz-sys has a feature called bundled. But you cannot use the bundled feature with FT enabled unless you link the submodule in the tree since you need the headers. This is needed for platforms where FT is not installed like android.

5 changes: 5 additions & 0 deletions harfbuzz-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,13 @@ fn build_harfbuzz() {
cfg.cpp(true)
.flag_if_supported("-std=c++11") // for unix
.warnings(false)
.include("freetype-sys/freetype2/include/")
.file("harfbuzz/src/harfbuzz.cc");

if cfg!(feature = "freetype") {
cfg.define("HAVE_FREETYPE", "1");
}

if !target.contains("windows") {
cfg.define("HAVE_PTHREAD", "1");
}
Expand Down
1 change: 1 addition & 0 deletions harfbuzz-sys/freetype-sys
Submodule freetype-sys added at 074be1