ruuda / pris

A language for designing slides
https://docs.ruuda.nl/pris/
GNU General Public License v3.0
116 stars 5 forks source link

Unable to build on 32 bit platforms #8

Closed FortressBuilder closed 7 years ago

FortressBuilder commented 7 years ago

At the moment pris fails to build on 32 bit platforms. The problem seems to be in src/cairo.rs, line 231:

Glyph::new(self.0.index, self.0.x + dx, self.0.y + dy)

Glyph::new takes a u64 as the first parameter, but self.0.index is a c_ulong, which is a u32 on 32 bit platforms and thus cannot be implicitly converted into a u64. The solution is to explicitly cast it, which should work on both 32 and 64 platforms:

Glyph::new(self.0.index as u64, self.0.x + dx, self.0.y + dy)
ruuda commented 7 years ago

First of all, thank you for taking the time to try Pris and to file an issue. Apologies for the late reply, I somehow missed this issue.

I’ve pushed a fix in 1f651a7. Does that solve the issue for you?

FortressBuilder commented 7 years ago

Yes, thank you :-)