Skip to content
Draft
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
17 changes: 17 additions & 0 deletions recipes/recipes_emscripten/rasterio/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash


embuilder build libjpeg --pic

export EMSCRIPTEN_SYSROOT=$(em-config CACHE)/sysroot
export EMSCRIPTEN_INCLUDE=$EMSCRIPTEN_SYSROOT/include
export EMSCRIPTEN_LIB=$EMSCRIPTEN_SYSROOT/lib/wasm32-emscripten/pic


# add EMSCRIPTEN_INCLUDE to include in CFLAGS
export CFLAGS="$CFLAGS -I${EMSCRIPTEN_INCLUDE} -fPIC"

# add EMSCRIPTEN_LIB to lib path in LDFLAGS
export LDFLAGS="$LDFLAGS -L${EMSCRIPTEN_LIB} -fPIC"

${PYTHON} -m pip install . ${PIP_ARGS}
65 changes: 65 additions & 0 deletions recipes/recipes_emscripten/rasterio/recipe.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
context:
version: 1.4.3
name: rasterio

package:
name: ${{ name }}
version: ${{ version }}

source:
url: https://files.pythonhosted.org/packages/de/19/ab4326e419b543da623ce4191f68e3f36a4d9adc64f3df5c78f044d8d9ca/rasterio-${{ version }}.tar.gz
sha256: 201f05dbc7c4739dacb2c78a1cf4e09c0b7265b0a4d16ccbd1753ce4f2af350a

build:
number: 1

requirements:
build:
- python
- cython
- cross-python_emscripten-wasm32
- ${{ compiler("c") }}
- pip
- numpy
- setuptools
host:
- numpy
- libgdal-core
- proj-static
- python
- geos-static
- libiconv
- libtiff
- libpng
- zlib

run:
- libgdal-core
- numpy
- affine
- attrs
- certifi
- click
- cligj

tests:
- script: pytester
requirements:
build:
- pytester
run:
- pytester-run
files:
recipe:
- test_rasterio.py


about:
homepage: https://github.com/rasterio/rasterio
license: BSD-3-Clause
license_file: LICENSE.txt
summary: Fast and direct raster I/O for use with Numpy and SciPy

extra:
recipe-maintainers:
- DerThorsten
6 changes: 6 additions & 0 deletions recipes/recipes_emscripten/rasterio/test_rasterio.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import pytest


def test_rasterio():
import rasterio

Loading