Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/ppapi #253

Open
wants to merge 52 commits into
base: develop
Choose a base branch
from
Open

Feature/ppapi #253

wants to merge 52 commits into from

Conversation

clebeaupin
Copy link
Contributor

Readium ppapi plugin for chromium based projects (chrome, electron, ...)

clebeaupin and others added 30 commits April 1, 2016 15:08
- Remove commented code
- Do not throw an exception if no content module is found
- throw an exception only if the container cannot be opened
Then you can build it.

```
python bootstrap.py
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On Windows 10 with GitBash / GitShell (both MINGW64) I am getting this error:

$ python bootstrap.py
Cloning into 'vendor/gyp'...
remote: Sending approximately 11.16 MiB ...
remote: Total 17731 (delta 11205), reused 17731 (delta 11205)
Receiving objects: 100% (17731/17731), 11.16 MiB | 3.09 MiB/s, done.
Resolving deltas: 100% (11205/11205), done.
Checking connectivity... done.
Checking out files: 100% (1609/1609), done.
Cloning into 'vendor/ninja'...
remote: Counting objects: 9189, done.
remote: Total 9189 (delta 0), reused 0 (delta 0), pack-reused 9189
Receiving objects: 100% (9189/9189), 2.10 MiB | 2.23 MiB/s, done.
Resolving deltas: 100% (6522/6522), done.
Checking connectivity... done.
Clone gyp
Clone ninja
Build and install ninja
Traceback (most recent call last):
  File "bootstrap.py", line 191, in <module>
    install_ninja()
  File "bootstrap.py", line 112, in install_ninja
    utils.execute_command(cmd, os.path.join("vendor", "ninja"))
  File "C:\Users\Daniel\GitHub\readium-sdk\Platform\chrome-ppapi\utils.py", line 11, in execute_command
    p = subprocess.Popen(cmd, cwd=cwd_abs_path)
  File "C:\Python27\lib\subprocess.py", line 710, in __init__
    errread, errwrite)
  File "C:\Python27\lib\subprocess.py", line 958, in _execute_child
    startupinfo)
WindowsError: [Error 2] The system cannot find the file specified

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With Cygwin I am getting this error (but the script continues to NACL SDK install):

$ python bootstrap.py
Build and install ninja
bootstrapping ninja...
./src/inline.sh: line 16: $'\r': command not found
./src/inline.sh: line 20: $'\r': command not found
sed: -e expression #1, char 40: unknown option to `s'
od: write error: Broken pipe
./src/inline.sh: line 25: $'\r': command not found
when running:  "./src/inline.sh" kBrowsePy < ./src/browse.py > build/browse_py.h
Traceback (most recent call last):
  File "configure.py", line 449, in <module>
    variables=[('varname', 'kBrowsePy')])
  File "configure.py", line 160, in build
    self._run_command(self._expand(cmd, local_vars))
  File "configure.py", line 185, in _run_command
    subprocess.check_call(cmdline, shell=True)
  File "/usr/lib/python2.7/subprocess.py", line 540, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '"./src/inline.sh" kBrowsePy < ./src/browse.py > build/browse_py.h' returned non-zero exit status 127

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Follow-up failure in Cygwin:

Apply patches
fatal: can't open patch '/cygdrive/c/Users/Daniel/GitHub/readium-sdk/Platform/chrome-ppapi/patches/cygwin_nt-10.0.diff': No such file or directory
Create includes

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You must use classic cmd and not cygwin or mingw. Moreover I have tested with python 2.7 and not with 3.x

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm using Python 2.7
Same error in classic cmd (MS-DOS) but I suspect MingW commands are in the path ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I have forgotten to mention that you must put in your PATH the visual studio 2015 folder:
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just an additional note:
on my machine (Windows 10 with Visual Studio 2015 Community, including C++ compiler), I have vcvars32.bat in C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin, not vcvarsall.bat which is hard-coded in readium-sdk/Platform/chrome-ppapi/bootstrap.py. Once I fixed that filename, I was able to move forward with python bootstrap.py. However, now applyPatches fail because of CR-LF DOS vs. UNIX line endings in the DIFF patches. @clebeaupin is able to reproduce this too, I believe.

Cyrille Lebeaupin and others added 6 commits July 19, 2016 10:37
- "container:readStream" that returns an ArrayBuffer object
- "container:readMetadata" that returns a dictionnary containing title and authors metadata of parsed ebook
I will remove in next commits all code tied to the nacl sdk.
Focus on a cross platform compiler
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants