This repository has been archived on 2026-03-24. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
  • Dart 53.7%
  • CMake 14.2%
  • C++ 13.9%
  • Rust 13.2%
  • Shell 2.4%
  • Other 2.6%
Find a file
2024-07-14 21:45:06 +03:00
.github/workflows Update rust.yml 2024-05-03 00:35:43 +03:00
.vscode Added Flutter code 2024-04-23 17:00:59 +03:00
lib Added info_bar 2024-07-14 21:45:06 +03:00
linux Added info_bar 2024-07-14 21:45:06 +03:00
rust Added info_bar 2024-07-14 21:45:06 +03:00
rust_builder Added info_bar 2024-07-14 21:45:06 +03:00
windows Added info_bar 2024-07-14 21:45:06 +03:00
.gitignore Kept lib/src/rust folder 2024-04-23 21:58:19 +03:00
.metadata Added Flutter code 2024-04-23 17:00:59 +03:00
analysis_options.yaml Added Flutter code 2024-04-23 17:00:59 +03:00
flutter_rust_bridge.yaml Added Flutter code 2024-04-23 17:00:59 +03:00
pubspec.lock Added info_bar 2024-07-14 21:45:06 +03:00
pubspec.yaml Added info_bar 2024-07-14 21:45:06 +03:00
README.md Update README.md 2024-05-03 00:42:32 +03:00

HazTR

A GIS natural hazard analysis software.

Development

Ubuntu

Install Rust

Install GDAL

sudo apt install libgdal-dev

Install GEOS

sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt install libgeos-dev

Install Cmake dependencies

sudo apt install ninja-build build-essential libgtk-3-dev

Install Flutter (Do not use the snap version)

Install flutter_rust_bridge code generator

cargo install 'flutter_rust_bridge_codegen@^2.0.0-dev.0' cargo-expand

Clone Repository

git clone https://github.com/ManeraKai/haztr
cd haztr/

Generate Flutter Rust bindings

flutter_rust_bridge_codegen generate

Run

flutter run

Windows

Install Rust

Install Miniconda

Install GDAL.

conda install -c conda-forge gdal=3.6.2

Install GDAL Libraries

Download and extract release-1930-x64-gdal-3-8-4-mapserver-8-0-1-libs.zip. Then add the below as an environment variable.

  • GDAL_LIB_DIR: C:\xxxxxxxx\shgdal\release-1930-x64-gdal-3-8-4-mapserver-8-0-1-libs\

Install GEOS

conda install -c conda-forge geos=3.11.1

Look where \include\geos\ is in your conda system files. Then add the below as environment variables:

  • GEOS_LIB_DIR: C:\xxxxxxxx\include\geos\
  • GEOS_VERSION: 3.11.1

Install pkg-config

conda install -c conda-forge pkg-config

Install Flutter

Install flutter_rust_bridge code generator

cargo install 'flutter_rust_bridge_codegen@^2.0.0-dev.0' cargo-expand

Clone Repository

git clone https://github.com/ManeraKai/haztr
cd haztr/

Generate Flutter Rust bindings

flutter_rust_bridge_codegen generate

Run

flutter run

Note

When changing rust code, run

flutter_rust_bridge_codegen generate

or

flutter_rust_bridge_codegen generate --watch