octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: how to make mexbiosig work on mxe-octave


From: JohnD
Subject: RE: how to make mexbiosig work on mxe-octave
Date: Fri, 10 May 2019 07:51:37 -0400


> -----Original Message-----
> From: Alois Schloegl [mailto:address@hidden
> Sent: Friday, May 10, 2019 5:15 AM
> To: JohnD; address@hidden
> Subject: Re: how to make mexbiosig work on mxe-octave
> 
> On 09.05.19 19:45, JohnD wrote:
> >
> >
> >> -----Original Message-----
> >> From: Alois Schlögl [mailto:address@hidden
> >> Sent: Sunday, May 05, 2019 5:36 PM
> >> To: JohnD; address@hidden
> >> Subject: Re: how to make mexbiosig work on mxe-octave
> >>
> >> On 5/3/19 5:48 PM, JohnD wrote:
> >>>
> >>>> -----Original Message-----
> >>>> From: Alois Schlögl [mailto:address@hidden
> >>>> Sent: Friday, May 03, 2019 11:22 AM
> >>>> To: JohnD; address@hidden
> >>>> Subject: Re: how to make mexbiosig work on mxe-octave
> >>>>
> >>>> On 01.05.19 22:12, JohnD wrote:
> >>>>>> ------------------------------
> >>>>>>
> >>>>>> Message: 2
> >>>>>> Date: Wed, 1 May 2019 01:20:49 +0200
> >>>>>> From: Alois Schl?gl <address@hidden>
> >>>>>> To: <address@hidden>
> >>>>>> Subject: how to make mexbiosig work on mxe-octave
> >>>>>> Message-ID: <3780f755-22ea-4001-b7c8-
> >>>> address@hidden>
> >>>>>> Content-Type: text/plain; charset="utf-8"
> >>>>>>
> >>>>>>
> >>>>>> Dear maintainers of MXE-OCTAVE,
> >>>>>>
> >>>>>>
> >>>>>> mexbiosig [1] is a mex-file for loading about 50 different Biosig
> >>>>>> data formats [2] into octave. mexbiosig can than be installed in
> >>>>>> octave with
> >>>> ?
> >>>>>>     pkg install mexbiosig-X.Y.Z.src.tar.gz
> >>>>>>
> >>>>>> but requires that? libbiosig [1] is available on the host platform.
> >>>>>> libbiosig for windows can be compiled with mxe [3,4,5]. I tried to
> >>>>>> compile libbiosig within mxe-octave. However, this was not
> >>>>>> successful (I just copied src/libbiosig.mk from [5] into a recent
> >>>>>> mxe-octave directory and tried to run "make libbiosig" in the same
> >>>>>> way as I used to this
> >>>> mxe.
> >>>>>> It fails with the message "make: *** No rule to make target
> >>>>>> 'libbiosig'.? Stop."
> >>>>>>
> >>>>>> Therefore, I'm asking:
> >>>>>>
> >>>>>> 1) how to compile libbiosig within mxe-octave ? What do I miss here ?
> >>>>>>
> >>>>>> 2) would you consider including libbiosig into the official
> >>>>>> mxe-octave repository ? What is needed to include this in Octave
> >>>>>> for
> >>>> windows ?
> >>>>>> The procedure to install mexbiosig in Octave is working fine on?
> >>>>>> Linux and macOS through homebrew. It would be great if mexbiosig
> >>>>>> could be also provided to Octave users on Windows. Could you help
> >>>>>> me with
> >>>> that ?
> >>>>>>
> >>>>>> Best regards,
> >>>>>>
> >>>>>> ? Alois
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> [1] http://biosig.sourceforge.net/download.html
> >>>>>>
> >>>>>> [2] http://pub.ist.ac.at/~schloegl/biosig/TESTED
> >>>>>>
> >>>>>> [3] https://mxe.cc/
> >>>>>>
> >>>>>> [4] https://github.com/schloegl/mxe
> >>>>>>
> >>>>>> [5] https://github.com/schloegl/mxe/blob/master/src/libbiosig.mk
> >>>>>>
> >>>>>>
> >>>>>> -------------- next part -------------- An HTML attachment was
> >>>>>> scrubbed...
> >>>>>
> >>>>> Looks like from biosig4c++, you should be running make -f
> >>>>> Makefile.win32 It currently fails in the build though with error:
> >>>>> conflicting types for 'sopen'
> >>>>>
> >>>>
> >>>> Dear John,
> >>>>
> >>>>
> >>>> Yes, it's possible to cross-compile libbiosig on linux for windows.
> >>>> Usually, I do this with mxe.
> >>>>    git clone https://github.com/schloegl/mxe.git
> >>>>    cd mxe
> >>>>    make libbiosig
> >>>>
> >>>> The approach if "make -f Makefile.win32" is not supported anymore,
> >>>> but should be replaced with something like
> >>>>     TARGET=$(TARGET) CROSS=$(TARGET) make libbiosig
> >>>>
> >>>> Currently, I'm trying with the attached makefile which I put into
> >>>>     mxe-octave/src/libbiosig.mk
> >>>> and apply to attached patch
> >>>>
> >>>> When trying to run
> >>>>     mxe-octave$ make libbiosig
> >>>> it does not do much. Any idea what else is needed ?
> >>>>
> >>>>
> >>>> Best, Alois
> >>>>
> >>>>
> >>>>
> >>>>
> >>> Im assuming you ran configure in the mxe-octave directory and its not
> issues
> >> with that.
> >>
> >> I was not aware about the need to run configure (thanks for the hint).
> >>
> >> And yes is does not show any issues.
> >>
> >>
> >>>
> >>> Mxe-octave was based on an older version of mxe, where I believe there
> was
> >> only a PKG_BUILD target being called, so you need to create a section for:
> >>>
> >>> define $(PKG)_BUILD
> >>> endef
> >>>
> >>> and in it call the correct target build
> >>>
> >>>
> >>> Some of the dependencies you have haven't been built in a long time, so
> may
> >> be rather out of date, or no longer compile in mxe-octave, but I guess you
> will
> >> find that out soon enough if that’s the case.
> >>
> >>
> >> The attached patches and make file compiles libbiosig v1.9.4 . I had to
> disable
> >> dicom waveform support, but libbiosig will still be quite useful.
> >>
> >> Could you include these in mxe-octave ?
> >>
> >>
> >> Cheers,
> >>
> >>    Alois
> >>
> >
> >
> >
> > That’s still  didn’t work for me in mxe-octave, however I managed to get
> something working for em and pushed:
> >
> > https://hg.octave.org/mxe-octave/rev/01ced4433575
> >
> >
> 
> 
> Dear John D.,
> 
> 
> looks good to me. For testing this, the following commands should run
> without error:
> 
> %%% installing mexbiosig %%%
> pkg install
> https://pub.ist.ac.at/~schloegl/biosig/prereleases/mexbiosig-1.9.4.src.tar.gz
> 
> %%% load mexbiosig %%%
> pkg load mexbiosig
> 
> %%% check mexSLOAD - it shows how to use mexSLOAD %%%
> mexSLOAD
> 
> %%% load data [1] using mexSLOAD %%%
> [s,HDR]=mexSLOAD('SC4002E0-PSG.edf');
> 
> % this fails for me when I build mxe-octave and run it on Windows
> plot(s(1:1e5,1))
> 
> 
> 
> 
> Best,
>    Alois
> 
> 
> 
> [1]
> https://alpha.physionet.org/static/published-projects/sleep-edfx/1.0.0/sleep-
> cassette/SC4002E0-PSG.edf
> 
> 
> 

I had verified pkg install worked butb was nt sure on the functions, but this 
works for me in dev octave 5.1.1:

>> [s,HDR]=mexSLOAD('SC4002E0-PSG.edf');
ERROR 3: Error SOPEN(READ); Cannot open file.

>> urlwrite 
>> ('https://physionet.org/pn6/sleep-edfx/sleep-cassette/SC4002E0-PSG.edf', 
>> 'SC4002E0-PSG.edf')

>> [s,HDR]=mexSLOAD('SC4002E0-PSG.edf');
Warning mexSLOAD: Overflowdetection not supported in file SC4002E0-PSG.edf

>> plot(s(1:1e5,1))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]