Skip to content

Commit

Permalink
Update proj to 9.3.1 (#182)
Browse files Browse the repository at this point in the history
* update proj source to 9.3.1

* update update documentation for maintainers

* new bindings for docs.rs

* update ci

* update rust versions

* Bump MSRV to 1.65

I don't know of any actual incompatibilities, but this is as far back
as we're willing to build CI images for.

* update changelog

---------

Co-authored-by: Michael Kirk <mkirk@endoftheworl.de>
  • Loading branch information
michaelkirk and Michael Kirk committed Dec 11, 2023
1 parent 154c0aa commit 8db09d6
Show file tree
Hide file tree
Showing 10 changed files with 28 additions and 16 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ jobs:
matrix:
container_image:
# Minimum supported rust (MSRV)
- "georust/proj-ci:proj-9.2.1-rust-1.63"
- "georust/proj-ci:proj-9.3.1-rust-1.65"
# Latest stable rust
- "georust/proj-ci:proj-9.2.1-rust-1.70"
- "georust/proj-ci:proj-9.3.1-rust-1.74"
features:
- ""
- "--features network"
Expand Down Expand Up @@ -98,34 +98,34 @@ jobs:
include:
# Minimum supported rust (MSRV)
- container:
image: georust/proj-ci:proj-9.2.1-rust-1.63
image: georust/proj-ci:proj-9.3.1-rust-1.65
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 0
features: ""
- container:
image: georust/proj-ci:proj-9.2.1-rust-1.63
image: georust/proj-ci:proj-9.3.1-rust-1.65
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 1
features: "--features bundled_proj"
- container:
image: georust/proj-ci-without-system-proj:proj-9.2.1-rust-1.63
image: georust/proj-ci-without-system-proj:proj-9.3.1-rust-1.65
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 1
features: ""

# Latest stable rust
- container:
image: georust/proj-ci:proj-9.2.1-rust-1.70
image: georust/proj-ci:proj-9.3.1-rust-1.74
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 0
features: ""
- container:
image: georust/proj-ci:proj-9.2.1-rust-1.70
image: georust/proj-ci:proj-9.3.1-rust-1.74
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 1
features: "--features bundled_proj"
- container:
image: georust/proj-ci-without-system-proj:proj-9.2.1-rust-1.70
image: georust/proj-ci-without-system-proj:proj-9.3.1-rust-1.74
env:
_PROJ_SYS_TEST_EXPECT_BUILD_FROM_SRC: 1
features: ""
Expand Down
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changes

## Unreleased

- Bump MSRV to 1.65

## 0.27.2

- Update to proj-sys 0.23.2 (libproj 9.2.1)
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ keywords = ["proj", "projection", "osgeo", "geo"]
license = "MIT OR Apache-2.0"
readme = "README.md"
edition = "2018"
rust-version = "1.63"
rust-version = "1.65"

[dependencies]
proj-sys = { version = "0.23.1", path = "proj-sys" }
Expand Down
6 changes: 6 additions & 0 deletions proj-sys/CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# Unreleased

- Update to PROJ 9.3.1
- Bump MSRV to 1.65


# 0.23.2

- Add explicit `tiff` feature for people using tiff files outside of `network`
Expand Down
1 change: 1 addition & 0 deletions proj-sys/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ keywords = ["proj", "projection", "osgeo", "geo", "geospatial"]
license = "MIT OR Apache-2.0"
edition = "2021"
links = "proj"
rust-version = "1.65"

[dependencies]

Expand Down
5 changes: 3 additions & 2 deletions proj-sys/MAINTAINERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,14 @@ expect docs.rs to do.

## To update the prebuilt bindings

Currently, the process looks like:
After updating the source in PROJSRC and the build.rs script to reference the new source,
The process of updating bindings looks like:

```
cd proj-sys
cargo clean
cargo build
find ../target/proj-sys-* -name bindings_docs-rs.rs
find ../target/debug/build/proj-sys* -name bindings.rs
```

copy that file over the `src/bindings_docs-rs.rs`, but retain the header:
Expand Down
Binary file removed proj-sys/PROJSRC/proj-9.2.1.tar.gz
Binary file not shown.
Binary file added proj-sys/PROJSRC/proj-9.3.1.tar.gz
Binary file not shown.
6 changes: 3 additions & 3 deletions proj-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use std::fs::File;
use std::path::PathBuf;
use tar::Archive;

const MINIMUM_PROJ_VERSION: &str = "9.2.0";
const MINIMUM_PROJ_VERSION: &str = "9.3.0";

#[cfg(feature = "nobuild")]
fn main() {} // Skip the build script on docs.rs
Expand Down Expand Up @@ -81,13 +81,13 @@ fn build_from_source() -> Result<std::path::PathBuf, Box<dyn std::error::Error>>
}

// NOTE: The PROJ build expects Sqlite3 to be present on the system.
let path = "PROJSRC/proj-9.2.1.tar.gz";
let path = "PROJSRC/proj-9.3.1.tar.gz";
let out_path = PathBuf::from(env::var("OUT_DIR").unwrap());
let tar_gz = File::open(path)?;
let tar = GzDecoder::new(tar_gz);
let mut archive = Archive::new(tar);
archive.unpack("PROJSRC/proj")?;
let mut config = cmake::Config::new("PROJSRC/proj/proj-9.2.1");
let mut config = cmake::Config::new("PROJSRC/proj/proj-9.3.1");
config.define("BUILD_SHARED_LIBS", "OFF");
config.define("BUILD_TESTING", "OFF");
config.define("BUILD_CCT", "OFF");
Expand Down
4 changes: 2 additions & 2 deletions proj-sys/src/bindings_docs-rs.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/* automatically generated by rust-bindgen 0.66.1 */
/* THESE ARE NOT LIVE BINDINGS */
/* THEY EXIST FOR USE BY DOCS-RS ONLY */
/* automatically generated by rust-bindgen 0.68.1 */

pub const PROJ_VERSION_MAJOR: u32 = 9;
pub const PROJ_VERSION_MINOR: u32 = 2;
pub const PROJ_VERSION_MINOR: u32 = 3;
pub const PROJ_VERSION_PATCH: u32 = 1;
pub const PJ_DEFAULT_CTX: u32 = 0;
pub const PROJ_ERR_INVALID_OP: u32 = 1024;
Expand Down

0 comments on commit 8db09d6

Please sign in to comment.