зеркало из https://github.com/mozilla/kitsune.git
optipng won't compile on mac silicon (#5581)
- create a Make option 'init-mac' to account for it - allow run-boostrap.sh to process the new --optipng-fix flag Open to better ideas (yes, move to linux is valid) - Determining if you are on Apple silicon from run-bootstrap directly appeared to be problematic since it is running in a container - Doing it prior in the make call seemed to make sense - change nothing for exisitng processes but add a simpler way forward for Mac folk
This commit is contained in:
Родитель
7e771b3d8b
Коммит
be21341d9a
3
Makefile
3
Makefile
|
@ -47,6 +47,9 @@ run: start
|
|||
init: .docker-build
|
||||
${DC} run web bin/run-bootstrap.sh
|
||||
|
||||
init-mac: .docker-build
|
||||
${DC} run web bin/run-bootstrap.sh --optipng-fix
|
||||
|
||||
shell: .docker-build
|
||||
${DC} run web bash
|
||||
|
||||
|
|
|
@ -5,6 +5,12 @@ set -ex
|
|||
# Install and setup localization
|
||||
./scripts/l10n-fetch-lint-compile.sh
|
||||
|
||||
# If flag --optipng-fix is passed
|
||||
if [[ $* == *--optipng-fix* ]]; then
|
||||
# Install fix for optipng on mac silicon
|
||||
export CPPFLAGS=-DPNG_ARM_NEON_OPT=0
|
||||
fi
|
||||
|
||||
# Collect the JavaScript catalog files.
|
||||
python manage.py compilejsi18n
|
||||
|
||||
|
|
|
@ -26,9 +26,21 @@ and follow the following steps.
|
|||
```
|
||||
|
||||
3. Pull base Kitsune Docker images, install node packages and build the Webpack bundle, and create your database.
|
||||
On non-Apple silicon:
|
||||
|
||||
```
|
||||
make init
|
||||
```
|
||||
|
||||
On Apple silicon (M1, M2):
|
||||
|
||||
```
|
||||
make init-mac
|
||||
```
|
||||
|
||||
Then:
|
||||
|
||||
```
|
||||
make build
|
||||
```
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче