Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Fix Build CI #79

Open
wants to merge 23 commits into
base: master
Choose a base branch
from
Open

Fix Build CI #79

wants to merge 23 commits into from

Conversation

lkashef
Copy link
Contributor

@lkashef lkashef commented May 15, 2020

  • Bum Xcode Image (f1bfd2c)
  • Fix install-emscripten.sh
    • Choose another source for emsdk, as this source seems to be no longer working
    • Comment out the workaround in for now (might be unnecessary as we are using a more recent version of emsdk)
    • Fix cache for new emsd location in circleci job
  • Fix emsdk location in script/build-browser-version.sh
  • Fix compilation errors after bumping emsdk
    • ...emscripten/bind.h:1391:13: error: implicit instantiation of undefined template 'emscripten::internal::RegisterClassConstructor<emscripten::val>'
    • error: no member named 'invoke' in 'emscripten::class_<Patch, emscripten::internal::NoBaseClass>'

lkashef added 8 commits May 15, 2020 14:32
Still getting same error "failed to create host: Image xcode:10.14.4 is not supported", trying with the oldest supported version
Correct EMSDK path
@lkashef lkashef changed the title Bump xcode to 10.3 Fix Build CI May 15, 2020
@lkashef
Copy link
Contributor Author

lkashef commented May 15, 2020

@maxbrunsfeld any input on the errors?

@aminya
Copy link
Contributor

aminya commented Oct 31, 2020

This is a hard one to fix. I found the documentation for this. https://emscripten.org/docs/porting/connecting_cpp_and_javascript/embind.html#using-val-to-transliterate-javascript-to-c

I am trying to read this to see if something has changed.

.constructor<emscripten::val>(WRAP_STATIC(&constructor), emscripten::allow_raw_pointers())

I can reproduce this error with emsdk 2.0.8

Here is the reproduction:

git clone https://github.com/aminya/superstring -b bump-xcode-on-circleci
cd superstring
mkdir -p build

Build (in bash):

#!/usr/bin/env bash

mkdir -p build

## Compile pcre

emcc                                         \
  -O3                                        \
  -I vendor/pcre/10.23/src                   \
  -I vendor/pcre/include                     \
  -D HAVE_CONFIG_H                           \
  -D PCRE2_CODE_UNIT_WIDTH=16                \
  -c                                         \
  vendor/pcre/pcre2_chartables.c             \
  vendor/pcre/10.23/src/pcre2_auto_possess.c \
  vendor/pcre/10.23/src/pcre2_compile.c      \
  vendor/pcre/10.23/src/pcre2_config.c       \
  vendor/pcre/10.23/src/pcre2_context.c      \
  vendor/pcre/10.23/src/pcre2_dfa_match.c    \
  vendor/pcre/10.23/src/pcre2_error.c        \
  vendor/pcre/10.23/src/pcre2_find_bracket.c \
  vendor/pcre/10.23/src/pcre2_jit_compile.c  \
  vendor/pcre/10.23/src/pcre2_maketables.c   \
  vendor/pcre/10.23/src/pcre2_match.c        \
  vendor/pcre/10.23/src/pcre2_match_data.c   \
  vendor/pcre/10.23/src/pcre2_newline.c      \
  vendor/pcre/10.23/src/pcre2_ord2utf.c      \
  vendor/pcre/10.23/src/pcre2_pattern_info.c \
  vendor/pcre/10.23/src/pcre2_serialize.c    \
  vendor/pcre/10.23/src/pcre2_string_utils.c \
  vendor/pcre/10.23/src/pcre2_study.c        \
  vendor/pcre/10.23/src/pcre2_substitute.c   \
  vendor/pcre/10.23/src/pcre2_substring.c    \
  vendor/pcre/10.23/src/pcre2_tables.c       \
  vendor/pcre/10.23/src/pcre2_ucd.c          \
  vendor/pcre/10.23/src/pcre2_valid_utf.c    \
  vendor/pcre/10.23/src/pcre2_xclass.c

mv *.o build/

emar                         \
  rcs build/pcre.a           \
  build/*.o

rm build/*.o

### Compile superstring

em++                                    \
  --bind                                \
  -o browser.js                         \
  -O3                                   \
  -I src/bindings/em                    \
  -I src/core                           \
  -I vendor/libcxx                      \
  -I vendor/pcre/include                \
  -D PCRE2_CODE_UNIT_WIDTH=16           \
  -xc++                                 \
  --pre-js src/bindings/em/prologue.js  \
  --post-js src/bindings/em/epilogue.js \
  src/core/*.cc                         \
  src/bindings/em/*.cc                  \
  build/pcre.a                          \
  -s TOTAL_MEMORY=134217728             \
  --memory-init-file 0                  \
  "$@"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants