Git Product home page Git Product logo

reprocessing-example's People

Contributors

bsansouci avatar jozanza avatar nielsbom avatar schmavery avatar vkammerer avatar zploskey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

reprocessing-example's Issues

Firefox 58.0.1 64 bit Ubuntu 16.04 64 bit

  • npm run build:web worked, although it did generate a warning about possibly unsafe polymorphic comparison use.
  • then python -m SimpleHTTPServer
  • opened localhost:8000 in Firefox and got a blank page
  • opened index.html directly in Firefox and got a blank page

might be good to have more explanation of how to get it working in FF and Chrome in addition to Safari?

Ubuntu 16.04 x86_64 failure

after the npm install etc. trying to do

$ npm run build
...
FAILED: indexhot.byte 
/home/superman/Dev/rml/Test/reprocessing-example/node_modules/bs-platform/lib/bsb_helper.exe  -add-ocaml-dependency bigarray -add-ocaml-dependency dynlink -add-ocaml-dependency nums -add-ocaml-dependency str -add-ocaml-dependency threads -add-ocaml-dependency unix -w -30-40+6+7+27+32..39+44+45+101  -bs-main IndexHot -bs-super-errors -add-clib -ccopt -add-clib -lasound -add-clib -ccopt -add-clib -lm -add-clib -ccopt -add-clib -ldl -add-clib -ccopt -add-clib -lpulse-simple -add-clib -ccopt -add-clib -lpulse -add-clib -ccopt -add-clib -lpthread -add-clib -ccopt -add-clib -lrt -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Reasongl/lib/reasongl.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/glad.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/image_helper.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/stb_image_aug.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/image_DXT.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/SOIL.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/soil_wrapper.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/tgls_new.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tsdl/lib/tsdl_new.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/libSDL2.a  -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tsdl/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Reasongl/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/reprocessing/lib/ocaml/bytecode src/IndexHot.mlast src/index.mlast -link-bytecode indexhot.byte
/usr/bin/ld: cannot find -lpulse-simple
/usr/bin/ld: cannot find -lpulse
collect2: error: ld returned 1 exit status

so then i installed libpulse-dev, which helped. but then:

FAILED: indexhot.byte 
/home/superman/Dev/rml/Test/reprocessing-example/node_modules/bs-platform/lib/bsb_helper.exe  -add-ocaml-dependency bigarray -add-ocaml-dependency dynlink -add-ocaml-dependency nums -add-ocaml-dependency str -add-ocaml-dependency threads -add-ocaml-dependency unix -w -30-40+6+7+27+32..39+44+45+101  -bs-main IndexHot -bs-super-errors -add-clib -ccopt -add-clib -lasound -add-clib -ccopt -add-clib -lm -add-clib -ccopt -add-clib -ldl -add-clib -ccopt -add-clib -lpulse-simple -add-clib -ccopt -add-clib -lpulse -add-clib -ccopt -add-clib -lpthread -add-clib -ccopt -add-clib -lrt -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Reasongl/lib/reasongl.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/glad.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/image_helper.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/stb_image_aug.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/image_DXT.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/SOIL.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/soil_wrapper.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/tgls_new.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tsdl/lib/tsdl_new.o -add-clib /home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/libSDL2.a  -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tsdl/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Tgls/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/Reasongl/lib/ocaml/bytecode -I /home/superman/Dev/rml/Test/reprocessing-example/node_modules/reprocessing/lib/ocaml/bytecode src/IndexHot.mlast src/index.mlast -link-bytecode indexhot.byte
/home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/libSDL2.a(SDL_mirvideo.o): In function `MIR_InitDisplayFromOutput':
/home/superman/Dev/rml/Test/reprocessing-example/node_modules/sdl2/src/video/mir/SDL_mirvideo.c:258: undefined reference to `mir_output_get_current_mode'
collect2: error: ld returned 1 exit status

Running `npm run build` fails on OS X

Here's the output I see in my terminal:

> reprocessing-example@ build /Users/fhsu/reference/reprocessing-example
> bsb -make-world

[2/2] Building fake_src/sdl_index.mlast.d
[2/2] Building lib.cma
[4/4] Building run_build_script
FAILED: run_build_script
/Users/fhsu/reference/reprocessing-example/node_modules/Tsdl/lib/bs/bytecode/build_script.exe /Users/fhsu/reference/reprocessing-example/node_modules/bs-platform/vendor /Users/fhsu/reference/reprocessing-example/node_modules/bs-platform/vendor/ocaml/lib/ocaml /Users/fhsu/reference/reprocessing-example/node_modules/Tsdl /Users/fhsu/reference/reprocessing-example
Fatal error: cannot load shared library dllunix
Reason: dlopen(/usr/local/lib/ocaml/stublibs/dllunix.so, 138): Symbol not found: _caml_ba_compare
  Referenced from: /usr/local/lib/ocaml/stublibs/dllunix.so
  Expected in: flat namespace
 in /usr/local/lib/ocaml/stublibs/dllunix.so
ninja: error: rebuilding 'build.ninja': subcommand failed
Failure: /Users/fhsu/reference/reprocessing-example/node_modules/bs-platform/lib/ninja.exe
 Location: /Users/fhsu/reference/reprocessing-example/node_modules/Tsdl/lib/bs/bytecode
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/fhsu/.npm/_logs/2018-07-02T18_39_59_156Z-debug.log

Issue with setup (tgls_bindings.a not found)

I cloned the repo and ran npm install which finished succesfully, followed by - npm run build which gives the following error -

ninja: error: '/tmp/reprocessing-example/node_modules/Tgls/tgls_bindings.a', needed by 'indexhot.byte', missing and no known rule to make it
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/anmol/.npm/_logs/2020-04-22T08_57_45_268Z-debug.log

Any tips on where I might be going wrong?

indexhot.byte not working in Windows 10

I've been trying to start working with Reprocessing but haven't been able to successfully run the starting project. I can build to web and native, but trying to hot reload on web is causing issues. When I run yarn start I get the following error:

Fatal error: exception Unix.Unix_error(21, "create_process", "node_modules\\.bin\\bsb")
error Command failed with exit code 2.

Trying to run npm start results in a longer log file I can post if necessary.

It seems like if I run python -m SimpleHTTPServer for web or yarn start:native I can still see the default output (blue square), but nothing I change seems to update it after restarting. I have a feeling that part might be user error, but I'm not sure. Besides start installing the dependencies and building the project seemed to go smoothly.

Issues on Sway (Wayland)

Hello! I've been getting errors when running this example on SwayWM/Wayland. After changing the bsb-native version in package.json to "^4.0.7000," I run the commands:

$ npm install
$ npm run build

All of which work as expected. However, once I run $ npm run start, things start up fine but then I get this error and it stops execution (segfault):

fish: "npm run start" terminated by signal SIGSEGV (Address boundary error)

With AwesomeWM this does not happen. Does Reprocessing support Wayland? If not, I can open an issue upstream on Reprocessing for Wayland support (if that’s wanted and necessary).

I think this happens with all Reprocessing examples, but the only other example I've tested is Resnake. Again, works on Xorg with Awesome, but not on Wayland with Sway.

Fresh install issues Ubuntu 18.04

Hey,

I am trying my best to get this up & running, but I am really struggling. Here are few different tries.

  1. Fresh start, nothing installed.
$ git clone https://github.com/bsansouci/reprocessing-example.git
Cloning into 'reprocessing-example'...
remote: Enumerating objects: 209, done.
remote: Total 209 (delta 0), reused 0 (delta 0), pack-reused 209
Receiving objects: 100% (209/209), 484.61 KiB | 1.34 MiB/s, done.
Resolving deltas: 100% (104/104), done.

$ cd reprocessing-example
$ npm install
> [email protected] postinstall /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/sdl2
> node postinstall.js

No pre-built binaries for linux, downloading source
Unzip successful.                          
Building from source, will take a minute or two.
Cloning into 'reprocessing-example'...
remote: Enumerating objects: 209, done.
remote: Total 209 (delta 0), reused 0 (delta 0), pack-reused 209
Receiving objects: 100% (209/209), 484.61 KiB | 1.34 MiB/s, done.
Resolving deltas: 100% (104/104), done.Looks like SDL2 built successfully.

> [email protected] postinstall /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/bsb-native
> node postinstall.js

Unzip successful.                            
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN reprocessing-example@ No repository field.
npm WARN reprocessing-example@ No license field.

added 11 packages from 8 contributors and audited 15 packages in 51.734s
found 0 vulnerabilities

$ npm run build

> reprocessing-example@ build /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example
> bsb -make-world

File "bsconfig.json", line 1
Error: package bs-platform is not found 
It's the basic, required package. If you have it installed globally,
Please run `npm link bs-platform` to make it available
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/cd/.npm/_logs/2019-09-10T17_43_03_339Z-debug.log

$ npm install -g bs-platform
/home/cd/.npm-packages/bin/bsb -> /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/bsb
/home/cd/.npm-packages/bin/bsrefmt -> /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/bsrefmt
/home/cd/.npm-packages/bin/bsc -> /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/bsc

> [email protected] postinstall /home/cd/.npm-packages/lib/node_modules/bs-platform
> node scripts/install.js

ninja binary is copied from pre-distribution
checkoutput: The OCaml compiler, version BuckleScript 5.0.6 (Using OCaml4.02.3+BS )
Standard library directory: /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/ocaml

Prebuilt compiler works good
[5/5] cp refmt.linux refmt.exe
Cleaning... 0 files.
[2/307] runtime/js.ml -> runtime/js.cmj runtime/js.cmi
Building runtime/js.ml
... (lot of lines)
[307/307] stdlib-402/bigarray.ml -> stdlib-402/bigarray.cmj    
Building stdlib-402/bigarray.ml
Build finished
+ [email protected]
updated 1 package in 3.386s

$ npm link bs-platform
/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/bs-platform -> /home/cd/.npm-packages/lib/node_modules/bs-platform

$ npm run build

> reprocessing-example@ build /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example
> bsb -make-world

[3/3] Building fake_src/sdl_index.cmj
[3/3] Building src/tsdl_new.cmj
[3/3] Building src/tgls_new.cmj
[1/30] Building src/events.mlast
File "/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/src/events.ml", line 1, characters 18-22:
Error: Conditional expression type mismatch (bool,string)
[2/30] Building src/reasongl.mlast
File "/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/src/reasongl.ml", line 1, characters 18-22:
Error: Conditional expression type mismatch (bool,string)
[10/30] Building src/web/reasongl_web.mlast
Failure: /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/ninja.exe 
 Location: /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/lib/bs
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/cd/.npm/_logs/2019-09-10T17_46_02_871Z-debug.log

No idea what is wrong and how it can be fixed.

  1. Globally installed bs-platform prior to start
$ git clone https://github.com/bsansouci/reprocessing-example.git && cd reprocessing-example && npm install
...(same output as before)

$ npm run build

> reprocessing-example@ build /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example
> bsb -make-world

bs-platform version mismatch Running bsb 4.0.11 (/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/bsb-native) vs vendored 5.0.6 (/home/cd/.npm-packages/lib/node_modules/bs-platform)
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/cd/.npm/_logs/2019-09-10T17_48_25_556Z-debug.log

Apparently there is a version mismatch, so I have tried to install a lower version of bs-platform.

  1. Global installation of bs-platform vs. 4.0.11
$ npm install -g [email protected]
$ npm link bs-platform
$ npm build
$ npm run build

> reprocessing-example@ build /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example
> bsb -make-world

[2/2] Building fake_src/sdl_index.mlast.d
[1/1] Building fake_src/sdl_index.cmj
[2/2] Building src/tsdl_new.mlast.d
[1/1] Building src/tsdl_new.cmj
File "/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Tsdl/src/tsdl_new.re", line 187, characters 21-28:
Warning: Unimplemented primitive used:TSDL_GetError 

[2/2] Building src/tgls_new.mlast.d
[1/1] Building src/tgls_new.cmj
[1/20] Building src/events.mlast
File "/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/src/events.ml", line 1, characters 18-22:
Error: Conditional expression type mismatch (bool,string)
[2/20] Building src/reasongl.mlast
File "/home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/src/reasongl.ml", line 1, characters 18-22:
Error: Conditional expression type mismatch (bool,string)
[10/20] Building src/native/reasongl_native.mlast
ninja: error: rebuilding 'build.ninja': subcommand failed
Failure: /home/cd/.npm-packages/lib/node_modules/bs-platform/lib/ninja.exe 
 Location: /home/cd/Scripts/Tutorials/ReasonReprocessing/reprocessing-example/node_modules/Reasongl/lib/bs
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/cd/.npm/_logs/2019-09-10T17_52_31_742Z-debug.log

Some error again.

I would appreciate anything that would point me in the correct direction.

Unable to run `npm run build` on Ubuntu 17.10

Hi

I'm getting the following error when I run: npm run build, npm run build:web or npm run build:native:

✗ npm run build                 

> reprocessing-example@ build /home/jasoon/Documents/adhara/test/reprocessing-example
> bsb -make-world

ninja: no work to do.
[1/1] Building run_build_script
FAILED: run_build_script 
/home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/Tsdl/lib/bs/bytecode/build_script.exe /home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/bs-platform/vendor /home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/bs-platform/vendor/ocaml/lib/ocaml /home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/Tsdl /home/jasoon/Documents/adhara/test/reprocessing-example
Fatal error: cannot load shared library dllunix
Reason: /usr/lib/ocaml/stublibs/dllunix.so: undefined symbol: caml_string_is_c_safe
ninja: error: rebuilding 'build.ninja': subcommand failed
Failure: /home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/bs-platform/lib/ninja.exe 
 Location: /home/jasoon/Documents/adhara/test/reprocessing-example/node_modules/Tsdl/lib/bs/bytecode
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/jasoon/.npm/_logs/2018-04-24T20_19_38_157Z-debug.log

The same thing happened when I ran this command on this repo https://github.com/ekosz/reprocessing-example-flow-field (well after I capitalised Reprocessing in the bsconfig.json).

Example fails because of library naming issues

I got these two errors by simply following the instructions in the readme.

First error:
127.0.0.1 - - [14/Feb/2018 22:39:37] code 404, message File not found 127.0.0.1 - - [14/Feb/2018 22:39:37] "GET /node_modules/Reprocessing/lib/js/src/Reprocessing.js HTTP/1.1" 404 -
Cause: In node_modules the Reprocessing library was with a lowercase first letter: "reprocessing".
Fix: Rename reprocessing to Reprocessing in node_modules.

Second error:
127.0.0.1 - - [14/Feb/2018 22:46:14] code 404, message File not found 127.0.0.1 - - [14/Feb/2018 22:46:14] "GET /node_modules/reasongl/lib/js/src/RGLConstants.js HTTP/1.1" 404 -
Cause: In node_modules the reasongl library started with uppercase first letter: Reasongl.
Fix: Rename Reasongl to reasongl in node_modules.

Inconsistent assumptions error in merlin

First -- I am able to build and run the example as in the readme.

But, merlin complains. I open a file in src/foo.ml and I get an error from merlin telling me:

The files /Users/izzy/.opam/4.02.3+buckle-1/lib/ocaml/pervasives.cmi and /Users/izzy/repos/reprocessing-exampl...rocessing/lib/ocaml/bytecode/Reprocessing_Constants.cmi make inconsistent assumptions over interface Pervasives

I guess there's some issue being caused by my global ocaml installation?

js files get placed in src/, not in lib/js/src

I have managed to get the examples running using both the native and the js backends. I am surprised, however, that bsb -make-world -native js places the resulting index.js not in lib/js/src/, as is expected by the index.html file, but puts it in src/.

In fact, I don't have lib/js/src, only a lib/bs/js/src, with the following contents:

% ls -1 lib/bs/js/src/
index.cmi
index.cmj
index.cmt
index.mlast
index.mlast.d
IndexHot.cmi
IndexHot.cmj
IndexHot.cmt
IndexHot.mlast
IndexHot.mlast.d

Why the discrepancy?

Conflict with global bs-platform

From https://reasonml.chat/t/is-reprocessing-alive/2045/10
cc @jdeisenberg

reasonlab> rm -rf reprocessing-example
reasonlab> !?clone
git clone https://github.com/bsansouci/reprocessing-example.git
Cloning into 'reprocessing-example'...
remote: Enumerating objects: 6, done.
remote: Counting objects: 100% (6/6), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 215 (delta 2), reused 0 (delta 0), pack-reused 209
Receiving objects: 100% (215/215), 486.29 KiB | 5.40 MiB/s, done.
Resolving deltas: 100% (106/106), done.
reasonlab> cd reprocessing-example
reprocessing-example> ls
bsconfig.json  index.html  package.json  README.md  require_polyfill.js  src
reprocessing-example> npm install

> [email protected] postinstall /home/david/reasonlab/reprocessing-example/node_modules/sdl2
> node postinstall.js

No pre-built binaries for linux, downloading source
Unzip successful.                          
Building from source, will take a minute or two.
Looks like SDL2 built successfully.

> [email protected] postinstall /home/david/reasonlab/reprocessing-example/node_modules/bsb-native
> node postinstall.js

Unzip successful.                            
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN reprocessing-example@ No repository field.
npm WARN reprocessing-example@ No license field.

added 11 packages from 8 contributors and audited 15 packages in 50.28s
found 0 vulnerabilities

reprocessing-example> npm run build

> reprocessing-example@ build /home/david/reasonlab/reprocessing-example
> bsb -make-world

bs-platform version mismatch Running bsb 4.0.11 (/home/david/reasonlab/reprocessing-example/node_modules/bsb-native) vs vendored 6.2.1 (/home/david/.nvm/versions/node/v11.7.0/lib/node_modules/bs-platform)
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/david/.npm/_logs/2019-12-04T01_41_48_361Z-debug.log

Add github template functionnality to this repo

There is new repository template functionality offered by Github that allow users to click a button to generate a repo based on the template.

I think this is good because a link to the original template is added to generated repos and this allow forks to be used for real project forking to add new functionality or make contributions.
Also adds a /generate endpoint if you want to programmatically generate a repo in a tutorial.

Here are steps to make this repository a template.

I can't think of a reason not to add this.

`npm run start:native` and `npm run start` fail with "That operation is not supported"

System: Ubuntu 18.04. Note that I happen to have an OCaml compiler installed (the BuckleScript version), but this shouldn't make a difference.

All three build commands worked fine, but the two of the three start commands are not working, as you can see below.

start:native

$ npm run start:native

> reprocessing-example@ start:native /home/hanjiexi/reprocessing-example
> ./lib/bs/native/index.native

Fatal error: exception Failure("That operation is not supported")
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ start:native: `./lib/bs/native/index.native`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ start:native script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/hanjiexi/.npm/_logs/2018-10-23T05_49_49_922Z-debug.log

Referenced debug log:

0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'start:native' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'prestart:native', 'start:native', 'poststart:native' ]
5 info lifecycle reprocessing-example@~prestart:native: reprocessing-example@
6 info lifecycle reprocessing-example@~start:native: reprocessing-example@
7 verbose lifecycle reprocessing-example@~start:native: unsafe-perm in lifecycle true
8 verbose lifecycle reprocessing-example@~start:native: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/hanjiexi/reprocessing-example/node_modules/.bin:/home/hanjiexi/.opam/4.02.3+buckle-master/bin:/home/hanjiexi/.cargo/bin:/home/hanjiexi/.yarn/bin:/home/hanjiexi/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/lib/jvm/java-9-oracle/bin:/usr/lib/jvm/java-9-oracle/db/bin
9 verbose lifecycle reprocessing-example@~start:native: CWD: /home/hanjiexi/reprocessing-example
10 silly lifecycle reprocessing-example@~start:native: Args: [ '-c', './lib/bs/native/index.native' ]
11 silly lifecycle reprocessing-example@~start:native: Returned: code: 2  signal: null
12 info lifecycle reprocessing-example@~start:native: Failed to exec start:native script
13 verbose stack Error: reprocessing-example@ start:native: `./lib/bs/native/index.native`
13 verbose stack Exit status 2
13 verbose stack     at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack     at emitTwo (events.js:126:13)
13 verbose stack     at EventEmitter.emit (events.js:214:7)
13 verbose stack     at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at emitTwo (events.js:126:13)
13 verbose stack     at ChildProcess.emit (events.js:214:7)
13 verbose stack     at maybeClose (internal/child_process.js:915:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
14 verbose pkgid reprocessing-example@
15 verbose cwd /home/hanjiexi/reprocessing-example
16 verbose Linux 4.15.0-38-generic
17 verbose argv "/usr/bin/node" "/usr/bin/npm" "run" "start:native"
18 verbose node v8.12.0
19 verbose npm  v6.4.1
20 error code ELIFECYCLE
21 error errno 2
22 error reprocessing-example@ start:native: `./lib/bs/native/index.native`
22 error Exit status 2
23 error Failed at the reprocessing-example@ start:native script.
23 error This is probably not a problem with npm. There is likely additional logging output above.

start

npm run start

> reprocessing-example@ start /home/hanjiexi/reprocessing-example
> ./lib/bs/bytecode/indexhot.byte

ninja: no work to do.
bsb running with pid: 13072
Reloading hotloaded module
Successfully changed functions
Stale file detected :  /home/hanjiexi/reprocessing-example/.bsb.lock
Retry:
>>>> Start compiling
ninja: no work to do.
>>>> Finish compiling
Fatal error: exception Failure("Unknown error while loading plugin: Failure(\"That operation is not supported\")")
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ start: `./lib/bs/bytecode/indexhot.byte`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/hanjiexi/.npm/_logs/2018-10-23T05_50_53_388Z-debug.log

Referenced debug log:

1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'run', 'start' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle reprocessing-example@~prestart: reprocessing-example@
6 info lifecycle reprocessing-example@~start: reprocessing-example@
7 verbose lifecycle reprocessing-example@~start: unsafe-perm in lifecycle true
8 verbose lifecycle reprocessing-example@~start: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/hanjiexi/reprocessing-example/node_modules/.bin:/home/hanjiexi/.opam/4.02.3+buckle-master/bin:/home/hanjiexi/.cargo/bin:/home/hanjiexi/.yarn/bin:/home/hanjiexi/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/lib/jvm/java-9-oracle/bin:/usr/lib/jvm/java-9-oracle/db/bin
9 verbose lifecycle reprocessing-example@~start: CWD: /home/hanjiexi/reprocessing-example
10 silly lifecycle reprocessing-example@~start: Args: [ '-c', './lib/bs/bytecode/indexhot.byte' ]
11 silly lifecycle reprocessing-example@~start: Returned: code: 2  signal: null
12 info lifecycle reprocessing-example@~start: Failed to exec start script
13 verbose stack Error: reprocessing-example@ start: `./lib/bs/bytecode/indexhot.byte`
13 verbose stack Exit status 2
13 verbose stack     at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16)
13 verbose stack     at emitTwo (events.js:126:13)
13 verbose stack     at EventEmitter.emit (events.js:214:7)
13 verbose stack     at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at emitTwo (events.js:126:13)
13 verbose stack     at ChildProcess.emit (events.js:214:7)
13 verbose stack     at maybeClose (internal/child_process.js:915:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
14 verbose pkgid reprocessing-example@
15 verbose cwd /home/hanjiexi/reprocessing-example
16 verbose Linux 4.15.0-38-generic
17 verbose argv "/usr/bin/node" "/usr/bin/npm" "run" "start"
18 verbose node v8.12.0
19 verbose npm  v6.4.1
20 error code ELIFECYCLE
21 error errno 2
22 error reprocessing-example@ start: `./lib/bs/bytecode/indexhot.byte`
22 error Exit status 2
23 error Failed at the reprocessing-example@ start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 2, true ]

Appreciate any help!

Does not build properly on OpenSUSE 42.2, npm version 5.6.0

david@linux:~/reasonlab> git clone https://github.com/bsansouci/reprocessing-example.git
Cloning into 'reprocessing-example'...
remote: Counting objects: 151, done.
remote: Compressing objects: 100% (35/35), done.
remote: Total 151 (delta 19), reused 20 (delta 9), pack-reused 107
Receiving objects: 100% (151/151), 476.05 KiB | 0 bytes/s, done.
Resolving deltas: 100% (69/69), done.
david@linux:~/reasonlab> cd reprocessing-example
david@linux:~/reasonlab/reprocessing-example> npm install

> [email protected] postinstall /home/david/reasonlab/reprocessing-example/node_modules/sdl2
> node postinstall.js

No pre-built binaries for linux, downloading source
Unzip successful.                          
Building from source, will take a minute or two.
Looks like SDL2 built successfully.

> [email protected] postinstall /home/david/reasonlab/reprocessing-example/node_modules/bs-platform
> node postinstall.js

Unzip successful.                            
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN reprocessing-example@ No repository field.
npm WARN reprocessing-example@ No license field.

added 11 packages in 105.306s
david@linux:~/reasonlab/reprocessing-example> npm run build

> reprocessing-example@ build /home/david/reasonlab/reprocessing-example
> bsb -make-world

[2/2] Building fake_src/sdl_index.mlast.d
[2/2] Building lib.cma
[4/4] Building run_build_script
[3/3] Building lib.cma
[4/4] Building run_build_script
[3/3] Building lib.cma
[18/18] Building run_build_script
[8/10] Building src/native/reasongl_native.cmo

  Warning number 27
  /home/david/reasonlab/reprocessing-example/node_modules/Reasongl/src/native/reasongl_native.re 121:17-25
  
  119 ┆  * osx will give us and one that has an API comparable to OpenGL ES 2
        .0 which is what WebGL uses.
  120 ┆  */
  121 ┆ let init = (~screen=?, ~argv as _) => {
  122 ┆   /* Screen is ignored for now, we always just create a new window. *
        /
  123 ┆   if (Sdl.Init.init(Sdl.Init.video lor Sdl.Init.audio) != 0) {
  
  unused variable screen.
[10/10] Building lib.cma
[42/42] Building src/Reprocessing_Internal.mlast.d
[22/22] Building lib.cma
ninja: Entering directory `lib/bs/bytecode'
[4/4] Building src/index.mlast.d
[3/3] Building indexhot.byte
FAILED: indexhot.byte 
/home/david/reasonlab/reprocessing-example/node_modules/bs-platform/lib/bsb_helper.exe  -add-ocaml-dependency bigarray -add-ocaml-dependency dynlink -add-ocaml-dependency nums -add-ocaml-dependency str -add-ocaml-dependency threads -add-ocaml-dependency unix -w -30-40+6+7+27+32..39+44+45+101  -bs-main IndexHot -bs-super-errors -add-clib -ccopt -add-clib -lasound -add-clib -ccopt -add-clib -lm -add-clib -ccopt -add-clib -ldl -add-clib -ccopt -add-clib -lpthread -add-clib -ccopt -add-clib -lrt -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Reasongl/lib/reasongl.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/glad.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/image_helper.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/stb_image_aug.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/image_DXT.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/SOIL.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/soil_wrapper.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/tgls_new.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/Tsdl/lib/tsdl_new.o -add-clib /home/david/reasonlab/reprocessing-example/node_modules/sdl2/libSDL2.a  -I /home/david/reasonlab/reprocessing-example/node_modules/sdl2/lib/ocaml/bytecode -I /home/david/reasonlab/reprocessing-example/node_modules/Tsdl/lib/ocaml/bytecode -I /home/david/reasonlab/reprocessing-example/node_modules/Tgls/lib/ocaml/bytecode -I /home/david/reasonlab/reprocessing-example/node_modules/Reasongl/lib/ocaml/bytecode -I /home/david/reasonlab/reprocessing-example/node_modules/Reprocessing/lib/ocaml/bytecode src/IndexHot.mlast src/index.mlast -link-bytecode indexhot.byte
/usr/lib64/gcc/x86_64-suse-linux/5/../../../../x86_64-suse-linux/bin/ld: cannot find -lasound
collect2: error: ld returned 1 exit status

  We've found a bug for you!
  (No file name)
  
  Error while building custom runtime system
  
ninja: build stopped: subcommand failed.
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! reprocessing-example@ build: `bsb -make-world`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the reprocessing-example@ build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/david/.npm/_logs/2018-04-12T14_31_59_856Z-debug.log
david@linux:~/reasonlab/reprocessing-example> 

Web and native examples fail with runtime exception Not_found accessing hashtable

After f932a1c web and native examples both seem to raise a Not_found exception:

web:
throws Caml_builtin_exceptions.not_found accessing hotreloadData hashtable at:

    at Object.find (node_modules/bsb-native/lib/js/hashtbl.js:269:5)
    at Object.run (node_modules/reprocessing/lib/js/src/Reprocessing.js:143:20)
    at eval (lib/js/src/index.js:69:14)
    at loadScript (http://localhost:8000/require_polyfill.js:146:32)
    at http://localhost:8000/require_polyfill.js:149:1"

native:

$ OCAMLRUNPARAM=b npm run start:native

> reprocessing-example@ start:native /Users/jfriend/code/reprocessing-example
> ./lib/bs/native/index.native

Fatal error: exception Not_found
Raised at file "hashtbl.ml", line 136, characters 19-28
Called from file "/Users/jfriend/code/reprocessing-example/node_modules/reprocessing/src/Reprocess", line 119, characters 11-48
Called from file "/Users/jfriend/code/reprocessing-example/src/index.re", line 11, characters 0-22

Checking out 0a4739b and then running npm install, npm run clean and then building web or native seems to fix both issues.

`npm start` throws an error

I'm following the steps mentioned in README.md to run the app. On running npm start, I'm getting the following error:

> reprocessing-example@ start /Users/vaibhavtulsyan/reason101/reprocessing-example
> ./lib/bs/bytecode/index.byte

sh: ./lib/bs/bytecode/index.byte: No such file or directory
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! reprocessing-example@ start: `./lib/bs/bytecode/index.byte`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the reprocessing-example@ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

However, running npm run build:web and then running a simple python server seems to work.

`npm run build` error on the Ubuntu 19.04

I've tried building the [example-flow-field](https://github.com/ekosz/reprocessing-example-flow-field example) and I got this error:

> reprocessing-example@ build /home/tomasz/Desktop/projects/cp-flow
> bsb -make-world

ninja: no work to do.
[1/1] Building run_build_script
FAILED: run_build_script 
/home/tomasz/Desktop/projects/cp-flow/node_modules/Tsdl/lib/bs/bytecode/build_script.exe /home/tomasz/Desktop/projects/cp-flow/node_modules/bs-platform/vendor /home/tomasz/Desktop/projects/cp-flow/node_modules/bs-platform/vendor/ocaml/lib/ocaml /home/tomasz/Desktop/projects/cp-flow/node_modules/Tsdl /home/tomasz/Desktop/projects/cp-flow
Fatal error: cannot load shared library dllunix
Reason: /home/tomasz/.opam/default/lib/ocaml/stublibs/dllunix.so: undefined symbol: caml_ba_element_size
ninja: error: rebuilding 'build.ninja': subcommand failed
Failure: /home/tomasz/Desktop/projects/cp-flow/node_modules/bs-platform/lib/ninja.exe 
 Location: /home/tomasz/Desktop/projects/cp-flow/node_modules/Tsdl/lib/bs/bytecode

I'd gone through other issues, such as #8 but I still couldn't solve it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.