Open lapoigne opened 3 years ago
AFAIK none of the main contributors are using windows, so it'd be good to test this setup in CI.
Do you have any experience with using windows containers in GH actions? Would you be willing to add a job to https://github.com/georust/proj/blob/master/.github/workflows/test.yml?
Hi @lapoigne, apologies for the delay. As @michaelkirk says, we don't have anyone available to locally test this, but we're certainly interested in anything that improves the Windows experience for these crates.
I will look closer to add CI for windows platform.
I added windows in CI file. The 32bit platform is commented because we loose precision in floating number and the test fail. Maybe you just want remove this architecture. I edited some test because I get some insignificant change in some value like 1450880.2910605008 for 1450880.2910605003
bors try
Sorry to let this sit for so long. Thanks for adding the ci integration, let's try it out.
bors try
Already running a review
bors r-
bors retry
bors r+
one last try bors.
Bors is crashing, I'm going to follow up with some bors peeps.
update: done here https://forum.bors.tech/t/bors-crashing-resource-not-accessible-by-integration/571/3
update 2: looking into similarly errors reported, it seems like "editing the workflow file" is a common source of crashes between bors and gh
Using opus-rs as a starting point, I was able to compile proj https://github.com/rust-av/opus-rs/commit/9f04ec13880ae1c72ee3f0548a8f6fd45475d9c7
Given these assumptions.. :
C:\src\vcpkg
PKG_CONFIG_PATH
set to C:\src\vcpkg\installed\x64-windows\lib\pkgconfig
These commands should work fine. At least I was able to build my project on Windows :
chocolatey install pkgconfiglite
(requires elevated privileges)C:\src\vcpkg
.\vcpkg.exe install proj:x64-windows
cargo init
cargo add proj
cargo build
(NOTE: I don't know whether or not this alone will result in linking with a release build of proj C++-library.)
I'm just thinking that maybe instead of referring to vcpkg directly in build.rs and Cargo configurations, georust/proj could consider requiring pkgconfiglite
on Windows just like it requires pkg-config
on other platforms (?). Of course the process would have to be documented.
I guess one advantage of this approach would be that it might not actually depend on vcpkg since developers can choose their own method for compiling proj C++-library (or so I believe).
I hope this helps
Hi @wlinna! To clarify — it sounds like you were able to build with the unmodified proj release using the instructions you provided.
Is that right? Or did you have to modify the proj/proj-sys crate in some way?
That's right, all unmodified :) . Rust, cargo are also installed with default options. All I had to do was to install software and set env variables according to the steps I provided.
On Thursday, November 10, 2022, Michael Kirk @.***> wrote:
Hi @wlinna https://github.com/wlinna! To clarify — it sounds like you were able to build with the unmodified proj release using the instructions you provided.
Is that right? Or did you have to modify the proj/proj-sys crate in some way?
— Reply to this email directly, view it on GitHub https://github.com/georust/proj/pull/79#issuecomment-1309109547, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALHXLQZT7FROKWN3KATO4DWHPOW5ANCNFSM4YQYDIOQ . You are receiving this because you were mentioned.Message ID: @.***>
This is amazing! Thanks for the hint about pkgconfiglite
@wlinna. I was able to get proj building on CI for Python in https://github.com/geopolars/geopolars/pull/174
I added the support of vcpkg libraries in proj-sys. This allow to build proj-sys on windows with msvc without pkg-config.
To use vcpkg libraries on your rust program, you need:
To build, run
I'm new to rust, I hope this isn't to ugly in my implementation.