Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
DerThorsten committed Jan 8, 2025
1 parent 1cadf0f commit 6cec838
Show file tree
Hide file tree
Showing 43 changed files with 355 additions and 2,893 deletions.
98 changes: 49 additions & 49 deletions .github/workflows/build_recipes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -85,56 +85,56 @@ jobs:
run: |
python -m emci build changed $GITHUB_WORKSPACE/ origin/emscripten-3.1.73 HEAD
################################################################
# UPLOAD
################################################################
- name: Upload packages to Quetz
if: (github.event_name == 'push' && github.repository == 'emscripten-forge/recipes')
shell: bash -l {0}
env:
QUETZ_API_KEY: ${{ secrets.QUETZ_API_KEY }}
run: |
overall_success=true
# ################################################################
# # UPLOAD
# ################################################################
# - name: Upload packages to Quetz
# if: (github.event_name == 'push' && github.repository == 'emscripten-forge/recipes')
# shell: bash -l {0}
# env:
# QUETZ_API_KEY: ${{ secrets.QUETZ_API_KEY }}
# run: |
# overall_success=true

# Loop over {emscripten-wasm32, linux-64, noarch}
for platform in emscripten-wasm32 linux-64 noarch; do
if [ -d "${GITHUB_WORKSPACE}/output/${platform}" ]; then
cd "${GITHUB_WORKSPACE}/output/${platform}"
files=$(ls *.tar.bz2 2> /dev/null)
if [ -n "$files" ]; then
for package in $files; do
echo "Uploading ${package} for ${platform}"
# # Loop over {emscripten-wasm32, linux-64, noarch}
# for platform in emscripten-wasm32 linux-64 noarch; do
# if [ -d "${GITHUB_WORKSPACE}/output/${platform}" ]; then
# cd "${GITHUB_WORKSPACE}/output/${platform}"
# files=$(ls *.tar.bz2 2> /dev/null)
# if [ -n "$files" ]; then
# for package in $files; do
# echo "Uploading ${package} for ${platform}"

FILE_SHA256=$(sha256sum "${package}" | awk '{ print $1 }')
CURL_CMD=(
curl -H "X-API-Key: ${QUETZ_API_KEY}" -X POST
"https://beta.mamba.pm/api/channels/emscripten-forge/upload/${package}?sha256=${FILE_SHA256}&force=false"
--data-binary "@${package}"
-o response_body.txt
-w "%{http_code}"
-s
)
HTTP_STATUS=$( "${CURL_CMD[@]}" )
RESPONSE=$(<response_body.txt)
# FILE_SHA256=$(sha256sum "${package}" | awk '{ print $1 }')
# CURL_CMD=(
# curl -H "X-API-Key: ${QUETZ_API_KEY}" -X POST
# "https://beta.mamba.pm/api/channels/emscripten-forge/upload/${package}?sha256=${FILE_SHA256}&force=false"
# --data-binary "@${package}"
# -o response_body.txt
# -w "%{http_code}"
# -s
# )
# HTTP_STATUS=$( "${CURL_CMD[@]}" )
# RESPONSE=$(<response_body.txt)

# Check the HTTP status code and log appropriate message
if [[ "$HTTP_STATUS" -eq 201 ]]; then
echo "Upload succeeded for ${package} on ${platform}"
else
echo "Error: Upload failed with HTTP status $HTTP_STATUS"
echo "Response Body: $RESPONSE"
overall_success=false
fi
rm -f response_body.txt
done
fi
fi
done
# # Check the HTTP status code and log appropriate message
# if [[ "$HTTP_STATUS" -eq 201 ]]; then
# echo "Upload succeeded for ${package} on ${platform}"
# else
# echo "Error: Upload failed with HTTP status $HTTP_STATUS"
# echo "Response Body: $RESPONSE"
# overall_success=false
# fi
# rm -f response_body.txt
# done
# fi
# fi
# done

# Check if all uploads were successful
if [ "$overall_success" = false ]; then
echo "One or more uploads failed"
exit 1
else
echo "All uploads completed successfully"
fi
# # Check if all uploads were successful
# if [ "$overall_success" = false ]; then
# echo "One or more uploads failed"
# exit 1
# else
# echo "All uploads completed successfully"
# fi
8 changes: 8 additions & 0 deletions conda_build_config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,12 @@ pin_run_as_build:
max_pin: x.x
zeromq:
max_pin: x.x
python:


# Pinning packages


# blas
libblas:
- 3.8 *netlib
Expand All @@ -231,6 +234,9 @@ blas_impl:
- mkl
- blis

emscripten-abi:
- '3.1.73'

abseil_cpp:
- '20210324.2'
alsa_lib:
Expand Down Expand Up @@ -585,6 +591,8 @@ python_impl:
# # part of a zip_keys: python, python_impl, numpy
# - cpython # [not (osx and arm64)]
# - cpython
pytester:
- 1.0.12
qt:
- 5.12
qtkeychain:
Expand Down
5 changes: 3 additions & 2 deletions recipes/recipes/emscripten_emscripten-wasm32/recipe.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ context:
version: 3.1.73

build:
number: 2
number: 3


outputs:
Expand All @@ -29,7 +29,8 @@ outputs:
- python >=3.11
- nodejs 16.*
run_exports:
- ${{ pin_subpackage('emscripten-abi', lower_bound='x.x.x', upper_bound='x.x.x') }}
strong:
- ${{ pin_subpackage('emscripten-abi', lower_bound='x.x.x', upper_bound='x.x.x') }}

- package:
name: emscripten-abi
Expand Down
20 changes: 7 additions & 13 deletions recipes/recipes/pytester/recipe.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
context:
version: '1.0.11'
version: '1.0.14'

source:
- path: bin
Expand All @@ -13,34 +13,28 @@ outputs:
version: ${{ version }}

build:
number: 11
number: 0

noarch: python

requirements:
host:
- python
run:
- if: linux
then:
- pyjs_code_runner >= 3.0.0
- microsoft::playwright <1.42
else:
- pyjs_code_runner >= 3.0.0
- microsoft::playwright
- microsoft::playwright > 1.49.1
- pyjs_code_runner >= 3.0.0

- package:
name: pytester-run
version: ${{ version }}
build:
number: 11
number: 0
noarch: generic
requirements:
run:
- pyjs
- pytest <8
- python <3.12
- emscripten-abi==3.1.45
- pytest
- python


about:
Expand Down
25 changes: 24 additions & 1 deletion recipes/recipes_emscripten/cffi/build.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,25 @@
#!/bin/bash
${PYTHON} -m pip install .





# side module
# export EM_FORGE_SIDE_MODULE_LDFLAGS="${LDFLAGS_BASE} -s SIDE_MODULE=1"
# export EM_FORGE_SIDE_MODULE_CFLAGS="${EM_FORGE_CFLAGS_BASE} -I${PREFIX}/include"

# # wasm bigint
# export LDFLAGS="$LDFLAGS -sWASM_BIGINT"

echo "EM_FORGE_SIDE_MODULE_LDFLAGS" $EM_FORGE_SIDE_MODULE_LDFLAGS
echo "EM_FORGE_SIDE_MODULE_CFLAGS" $EM_FORGE_SIDE_MODULE_CFLAGS


LDFLAGS="$LDFLAGS $EM_FORGE_SIDE_MODULE_LDFLAGS"
CFLAGS="$CFLAGS $EM_FORGE_SIDE_MODULE_CFLAGS"

export LDFLAGS
export CFLAGS


ARCHFLAGS="" ${PYTHON} -m pip install . --verbose
21 changes: 10 additions & 11 deletions recipes/recipes_emscripten/cffi/recipe.yaml
Original file line number Diff line number Diff line change
@@ -1,36 +1,35 @@
context:
version: 1.15.1
version: 1.17.1

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

source:
- url: https://pypi.io/packages/source/c/cffi/cffi-${{ version }}.tar.gz
sha256: d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9
patches:
- patches/libffi-config.patch
sha256: 1c39c6016c32bc48dd54561950ebd6836e1670f2ae46128f67cf49e789c52824
# patches:
# - patches/libffi-config.patch
- path: setup.py

build:
number: 2
number: 1

requirements:
build:
- ${{ compiler('c') }}
- cross-python_emscripten-wasm32
- python
- ${{ compiler('c') }}
- pkg-config
- pip
host:
- python
- libffi
- pycparser
- pip
# run:
# - python
# - libffi
# - pycparser
- libffi
run:
- pycparser


tests:
- script: pytester
Expand Down
Loading

0 comments on commit 6cec838

Please sign in to comment.