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

Cannot compile node-sqlite3 #27

Open
nolanlawson opened this issue Jun 7, 2016 · 8 comments
Open

Cannot compile node-sqlite3 #27

nolanlawson opened this issue Jun 7, 2016 · 8 comments

Comments

@nolanlawson
Copy link
Contributor

nolanlawson commented Jun 7, 2016

Background: trying to get PouchDB to run on a Tessel. Tried leveldown, but ran into #14. Now trying the sqlite3 package (aka node-sqlite3), getting a different error (full gist):

/bin/sh: 1: Syntax error: "(" unexpected
make: *** [Debug/obj.target/<(module_name)/src/database.o] Error 2
make: Leaving directory `/work/binary-module/package/build'

@johnnyman727 and @velmont and I spent some time at the NodeConf Tessel workshop in Oslo trying to figure this out, with limited results. I'm still looking into it, but posting this issue so we can keep track of it.

To reproduce:

./compile.sh sqlite3
@reconbot
Copy link
Member

reconbot commented Jun 7, 2016

Ahh thanks! I've been meaning to make an issue for this.

@nolanlawson
Copy link
Contributor Author

OK, I got this to work, and I wrote down instructions for running PouchDB+SQLite on a Tessel: https://gist.github.com/nolanlawson/a7822b984865abc5bcf2268fad973102

Note that this relies LOTS of hacks and still needs a more formal solution IMO, but this is at least a start.

@johnnyman727
Copy link
Contributor

👏 Impressive persistence, @nolanlawson!

@nolanlawson
Copy link
Contributor Author

I couldn't have done it without you or @velmont. 😃

@odinho
Copy link

odinho commented Jun 16, 2016

Haha, -- well that's a good return on investment for borrowing you a USB stick ;) Awesome that you got it working.

@Arrow7000
Copy link

Hi @nolanlawson thanks for this! I am trying to run sqlite3 on its own, but am struggling to follow your Gist instructions. There's a lot of information and links to forked repos but I'm pretty new to this stuff and don't really know where to start.

Do I need to compile sqlite and manually paste it somewhere in node_modules? Do I need to specify in package.json somewhere that the module should be installed from your forked branches? I'm really lost. Any chance you could write up instructions that are a little more amateur friendly?

Thanks for all your work on this!

@rwaldron
Copy link
Contributor

Do I need to compile sqlite and manually paste it somewhere in node_modules

No, @nolanlawson did that and we pushed his binaries to the pre-compiled binary server. What version are you using? There are 2 pre-compiled modules for sqlite3 on our server:

  • sqlite3@3.1.1
  • sqlite3@3.1.4

In your local project, do:

npm install sqlite3@3.1.4

Does your application deploy to the Tessel 2 with that version?

@Arrow7000
Copy link

@rwaldron thanks for responding, I wish I could respond but as I'm currently constantly getting WARN No Tessels Found. for every command I try (tessel/t2-cli#742 (comment)) I can't test your solution yet.

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

No branches or pull requests

6 participants