Git Product home page Git Product logo

mex-sqlite3's Introduction

mex-sqlite3

An extension for MATLAB® or GNU/octave to access sqlite3 databases

Compilation for octave :

mkoctfile --mex -lsqlite3 -o sqlite3.mex sqlite3.c structlist.c

Then add resulting sqlite3.mex file to octave search path, for example :

% cd to your .mex file
p = genpath(pwd);
addpath(p);
savepath;

mex-sqlite3's People

Contributors

andy1978 avatar drm-free avatar rmartinjak avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

mex-sqlite3's Issues

Add to readme link to binaries, and correct mkoctfile line to create sqlite3.mex on macos

Please add to readme info below.
(1.) Macos and linux HOWTO.
To create sqlite3.mex on macosx or linux.

  • Macos brew install octave && git clone https://github.com/rmartinjak/mex-sqlite3.git
  • Linux. Get mkoctfile. Debian/Ubuntu: apt-get install liboctave-dev

mkoctfile --mex -lsqlite3 -loctave -o sqlite3.mex sqlite3.c structlist.c . && cp sqlite3.mex ~/octave/ && octave
GNU Octave, version 4.4.1
octave:1> sqlite3
error: sqlite3: usage: sqlite3(file, query[, params]

I tried putting sqlite3.mex in octave path, but only seems to find it if running from dir where it is. That is I have same problem in octave as does @chappjc in matlab per their comment at https://stackoverflow.com/questions/26189163/mex-compiled-function-not-recognized-by-matlab

Thanks, I its weird, I had to explicitly go to the directory of the mex file and only then did the function become available. Adding its directory via addpath(genpath('the/path')) did not work for some reason

I copied sqlite3.mex to ~/Documents/MATLAB/ but matlab still says Undefined function or variable 'sqlite3' so Matlab does not recognize .mex. Maybe sqlite3.mex is really is an .oct file, as mkoctfile creates identical files with and without --mex. If I rename it sqlite3.mexmaci64 it crashes matlab.

(2.) Windows and Linux binaries.
At matlab FEX site for sqlite3 you can download a zip with compiled_mex folder that has one linux binary, and all the rest are windows binaries:

862208 Apr 11 2018 sqlite3_matlab.exe 
966706 Mar 3 2017 sqlite3_matlab.mexa64 
741888 Mar 3 2017 sqlite3_matlab.mexw32 
962560 Mar 3 2017 sqlite3_matlab.mexw64 
29032 May 13 2018 sqlite3_octave_lnx_i686.mex 
145052 May 13 2018 sqlite3_octave_win_64.mex 
114247 May 13 2018 sqlite3_octave_win_i686.mex 

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.