Skip to content

Commit

Permalink
Windows toolchain update
Browse files Browse the repository at this point in the history
  • Loading branch information
neurodroid committed Jun 23, 2017
1 parent ec130d8 commit a5aa326
Show file tree
Hide file tree
Showing 16 changed files with 86 additions and 17 deletions.
5 changes: 5 additions & 0 deletions dist/windows/VS2008/Stimfit/Config.vsprops
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,9 @@
Name="PYTHONDIR"
Value="C:\Python27"
/>
<UserMacro
Name="NUMPYDIR"
Value="C:\Python27\Lib\site-packages\numpy\core\include"
/>

</VisualStudioPropertySheet>
Binary file modified dist/windows/VS2008/Stimfit/Stimfit.suo
Binary file not shown.
4 changes: 2 additions & 2 deletions dist/windows/VS2008/Stimfit/Stimfit.vcproj
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\Lib\site-packages\numpy\core\include&quot;"
PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
MinimalRebuild="true"
BasicRuntimeChecks="3"
Expand Down Expand Up @@ -278,7 +278,7 @@
Optimization="3"
EnableIntrinsicFunctions="true"
WholeProgramOptimization="false"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;"
AdditionalIncludeDirectories="&quot;$(PYTHONDIR)\include&quot;;&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\Lib\site-packages\numpy\core\include&quot;"
PreprocessorDefinitions="__STF__;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
Expand Down
32 changes: 32 additions & 0 deletions dist/windows/VS2008/libstfio/libstfio.vcproj
Original file line number Diff line number Diff line change
Expand Up @@ -587,6 +587,22 @@
>
</File>
</Filter>
<Filter
Name="intan"
>
<File
RelativePath="..\..\..\..\src\libstfio\intan\common.h"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\intanlib.h"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\streams.h"
>
</File>
</Filter>
</Filter>
<Filter
Name="Source Files"
Expand Down Expand Up @@ -787,6 +803,22 @@
>
</File>
</Filter>
<Filter
Name="intan"
>
<File
RelativePath="..\..\..\..\src\libstfio\intan\common.cpp"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\intanlib.cpp"
>
</File>
<File
RelativePath="..\..\..\..\src\libstfio\intan\streams.cpp"
>
</File>
</Filter>
</Filter>
<Filter
Name="Resource Files"
Expand Down
4 changes: 4 additions & 0 deletions dist/windows/VS2008/libstimfit/Config.vsprops
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,8 @@
Name="PYTHONDIR"
Value="C:\Python27"
/>
<UserMacro
Name="NUMPYDIR"
Value="C:\Python27\Lib\site-packages\numpy\core\include"
/>
</VisualStudioPropertySheet>
4 changes: 2 additions & 2 deletions dist/windows/VS2008/libstimfit/libstimfit.vcproj
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;;&quot;$(NUMPYDIR)&quot;"
PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
MinimalRebuild="true"
BasicRuntimeChecks="3"
Expand Down Expand Up @@ -281,7 +281,7 @@
Optimization="3"
EnableIntrinsicFunctions="true"
WholeProgramOptimization="false"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;"
AdditionalIncludeDirectories="&quot;$(BOOSTDIR)&quot;;&quot;$(WXDIR)\include&quot;;&quot;$(WXDIR)\lib\vc90_x64_dll\mswu&quot;;&quot;$(FFTWDIR)&quot;;&quot;$(PYTHONDIR)\include&quot;;&quot;$(NUMPYDIR)&quot;"
PreprocessorDefinitions="__STF__;STFDLL;_WIN64;_WINDOWS;_CRT_SECURE_NO_WARNINGS;HAVE_LAPACK;WXUSINGDLL;__WXMSW__;WXP_USE_THREAD=1;WITH_PYTHON;WITH_BIOSIG2"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
Expand Down
10 changes: 5 additions & 5 deletions dist/windows/nsis/installer.nsi
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,18 @@ SetCompressor lzma
!define WXW_VERSION "3.0.2.0"
!define WXW_VERSION_DIR "3.0.2"
!define WXW_VERSION_SHORT "30"
!define PY_VERSION "2.7.9"
!define PY_VERSION "2.7.13"
!define PY_MAJOR "2.7"
!define PY_MAJOR_SHORT "27"
!define PY_MIN "2.7"
!define PY_INST_FILE "python-${PY_VERSION}.amd64.msi"
Var PY_ACT
!define NP_VERSION "1.9.3"
!define MPL_VERSION "1.5.0"
!define NP_VERSION ""
!define MPL_VERSION ""
!define EMF_VERSION "2.0.0"
!define EXE_NAME "Stimfit"
!define REG_NAME "Stimfit 0.14"
!define REG_NAME_IO "stfio 0.14"
!define REG_NAME "Stimfit 0.15"
!define REG_NAME_IO "stfio 0.15"
!define PRODUCT_PUBLISHER "Christoph Schmidt-Hieber"
!define PRODUCT_WEB_SITE "http://www.stimfit.org"
!define STFDIR "..\..\..\..\stimfit"
Expand Down
3 changes: 2 additions & 1 deletion src/libstfio/intan/intanlib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,8 @@ std::vector<std::vector<float> > read_aux_data(BinaryReader& binreader, uint16_t

void stfio::importIntanFile(const std::string &fName, Recording &ReturnData, ProgressInfo& progDlg) {
unique_ptr<FileInStream> fs(new FileInStream());
fs->open(fName);
std::wstring wfName(fName.begin(), fName.end());
fs->open(wfName);

unique_ptr<BinaryReader> binreader(new BinaryReader(move(fs)));

Expand Down
14 changes: 14 additions & 0 deletions src/libstfio/intan/intanlib.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ as of 2016-11-05
>>> intan_file = intan.IntanFile('myexperiment_AUX_160916_142731.clp')
>>> plt.plot(intan_file.data["Time"], intan_file.data["ADC"][1])
*/
#ifndef INTANLIB_H
#define INTANLIB_H

#if __cplusplus > 199711L
#include <cstdint>
Expand All @@ -40,6 +42,17 @@ as of 2016-11-05

#include "./../stfio.h"

#ifdef _WINDOWS
typedef __int8 int8_t;
typedef __int16 int16_t;
typedef __int32 int32_t;
typedef __int64 int64_t;
typedef unsigned __int8 uint8_t;
typedef unsigned __int16 uint16_t;
typedef unsigned __int32 uint32_t;
typedef unsigned __int64 uint64_t;
#endif

class Recording;

static const int MAX_REGISTERS = 14;
Expand Down Expand Up @@ -128,3 +141,4 @@ namespace stfio {
void importIntanFile(const std::string &fName, Recording &ReturnData, ProgressInfo& progDlg);

}
#endif
7 changes: 7 additions & 0 deletions src/libstfio/intan/streams.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,17 @@ BinaryReader& operator>>(BinaryReader& istream, wstring& value) {
value.clear();
if (size > 0) {
vector<char> tmp(size + 2);
#ifndef _WINDOWS
istream.other->read(tmp.data(), size);
tmp[size] = 0;
tmp[size + 1] = 0;
value = reinterpret_cast<wchar_t*>(tmp.data());
#else
istream.other->read(&tmp[0], size);
tmp[size] = 0;
tmp[size + 1] = 0;
value = reinterpret_cast<wchar_t*>(&tmp[0]);
#endif
}
return istream;
}
Expand Down
1 change: 1 addition & 0 deletions src/libstfio/intan/streams.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ using boost::move;
#include <iosfwd>
#include <istream>

#include "./intanlib.h"

#if defined(_WIN32) && defined(_UNICODE)
typedef std::wstring FILENAME;
Expand Down
7 changes: 3 additions & 4 deletions src/libstfio/recording.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,10 @@ void Recording::init() {
cs = 0;
selectedSections = std::vector<std::size_t>(0);
selectBase = Vector_double(0);
sectionMarker = NULL;
sectionMarker = std::vector<int>(0);
}

Recording::~Recording() {
if (sectionMarker) free(sectionMarker);
}

const Channel& Recording::at(std::size_t n_c) const {
Expand Down Expand Up @@ -388,12 +387,12 @@ std::string Recording::GetEventDescription(int type) {
return listOfMarkers[type];
}

std::string Recording::SetEventDescription(int type, const char* Description) {
void Recording::SetEventDescription(int type, const char* Description) {
listOfMarkers[type] = Description;
}

void Recording::InitSectionMarkerList(size_t n) {
sectionMarker=(typeof(sectionMarker))calloc(n,sizeof(*sectionMarker));
sectionMarker.resize(n);
return;
}

Expand Down
4 changes: 2 additions & 2 deletions src/libstfio/recording.h
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ class StfioDll Recording {
std::string GetEventDescription(int type);

//! Set Description of Event Type
std::string SetEventDescription(int type, const char* Description);
void SetEventDescription(int type, const char* Description);

//! Initialize List of Section Markers
void InitSectionMarkerList(size_t n);
Expand Down Expand Up @@ -418,7 +418,7 @@ class StfioDll Recording {
as defined event table.
currently only one event type per segment is supported.
*/
int* sectionMarker=NULL;
std::vector<int> sectionMarker;

void init();

Expand Down
4 changes: 4 additions & 0 deletions src/stimfit/gui/app.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,10 @@ bool wxStfApp::OnInit(void)
wxT("HEKA file"), wxT("*.dat"), wxT(""), wxT("dat"),
wxT("HEKA Document"), wxT("HEKA View"), CLASSINFO(wxStfDoc),
CLASSINFO(wxStfView) );
m_intanTemplate=new wxDocTemplate( docManager,
wxT("Intan CLAMP file"), wxT("*.clp"), wxT(""), wxT("clp"),
wxT("Intan CLAMP Document"), wxT("Intan View"), CLASSINFO(wxStfDoc),
CLASSINFO(wxStfView) );
#if 0
m_sonTemplate=new wxDocTemplate( docManager,
wxT("CED Spike 2 (SON) file"), wxT("*.smr"), wxT(""), wxT(""),
Expand Down
2 changes: 1 addition & 1 deletion src/stimfit/gui/app.h
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ class StfDll wxStfApp: public wxApp
// Pointer to the cursors settings dialog box
wxStfCursorsDlg* CursorsDialog;
wxDocTemplate* m_cfsTemplate, *m_hdf5Template, *m_txtTemplate,*m_abfTemplate,
*m_atfTemplate,*m_axgTemplate,*m_sonTemplate, *m_hekaTemplate, *m_biosigTemplate;
*m_atfTemplate,*m_axgTemplate,*m_sonTemplate, *m_hekaTemplate, *m_intanTemplate, *m_biosigTemplate;
stfnum::storedFunc storedLinFunc;
// wxMenu* m_file_menu;
wxString m_fileToLoad;
Expand Down
2 changes: 2 additions & 0 deletions src/stimfit/stf.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,11 @@
#ifndef _STF_H_
#define _STF_H_

#ifndef _WINDOWS
#if (__cplusplus < 201103)
#include <boost/function.hpp>
#endif
#endif
#include <vector>
#include <map>
#include <string>
Expand Down

0 comments on commit a5aa326

Please sign in to comment.