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

103 windows build #23

Closed
wants to merge 41 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
aa62a21
Initial pass through CPPCheck
rcrowder Aug 19, 2014
92d6082
Pointing Travis to my account
rcrowder Aug 20, 2014
7f8139a
Initial AppVeyor Yaml file
rcrowder Sep 1, 2014
be39ccc
Fixes to Yml matrix
rcrowder Sep 1, 2014
12a678e
More Yml massage
rcrowder Sep 1, 2014
f772a7c
Updates to AppVeyor YAML, zconf.h and CMakeList
rcrowder Sep 1, 2014
958ec2a
Now GCC and MSVC in the matrix
rcrowder Sep 1, 2014
5e97e3c
AppVeyor format fix
rcrowder Sep 1, 2014
9ef7257
Addition of external libraries
rcrowder Sep 2, 2014
f2acf01
Revert mistakes made in CPPCheck commit
rcrowder Sep 3, 2014
fb119e7
More YAML fun
rcrowder Sep 3, 2014
aed0950
A new badge for the Readme.md
rcrowder Sep 3, 2014
a3a2216
Merge pull request #161 from utensil/103-windows-build
rhyolight Sep 4, 2014
c80c5e5
Trying the full nupic_core solution
rcrowder Sep 4, 2014
8672a7c
Setting up external libraries
rcrowder Sep 7, 2014
e9c476d
Build fix with apr header
rcrowder Sep 7, 2014
f94f9f9
Adding lib yaml
rcrowder Sep 8, 2014
d030247
One final library error to squash
rcrowder Sep 8, 2014
5085718
(temporarily) remove NULLpointer region InputTest
breznak Sep 5, 2014
6b6afc1
Merge pull request #181 from breznak/fix_null_dereference_clang3.5
scottpurdy Sep 8, 2014
3d7b06a
Environ change
rcrowder Sep 8, 2014
302c03c
Additions to CMakeLists
rcrowder Sep 10, 2014
9094ad2
Build fix
rcrowder Sep 10, 2014
a9e9670
Build fix
rcrowder Sep 10, 2014
bd10481
Build fix
rcrowder Sep 11, 2014
a566c08
Bad flags
rcrowder Sep 11, 2014
fb5dc4b
Oldnames?
rcrowder Sep 11, 2014
80df8aa
No safeseh
rcrowder Sep 11, 2014
9e6f723
Adding Windows application libraries
rcrowder Sep 11, 2014
35d3be3
Silly double quotes
rcrowder Sep 11, 2014
efb92ab
Ignoring libcmt
rcrowder Sep 11, 2014
b6d94b9
Test for nupic.tools auto PR feature.
rhyolight Sep 11, 2014
5ec7c01
Test 2 for nupic.tools auto PR feature.
rhyolight Sep 11, 2014
37d2750
Reduction of warnings
rcrowder Sep 12, 2014
52ae202
Return of C++98 for Travis
rcrowder Sep 12, 2014
1bf0c16
Try alternative test logging
rcrowder Sep 13, 2014
2ef9da3
Add missing directory OS code, bug fixes
rcrowder Sep 14, 2014
9b0dbcd
Using NTA_CHECK for directory creation failure
rcrowder Sep 14, 2014
eb6d404
Moving the green AppYevor badge
rcrowder Sep 14, 2014
428cef2
External library update
rcrowder Sep 15, 2014
0e06ee6
Merge conflicts resolved
rcrowder Sep 15, 2014
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,20 @@

# IDE project files
/nbproject/
*.sln
*.dsw
*.vcxproj
*.vcproj
*.dsp
*.dir/

# Build files
build/
*.obj
*.log
*.tlog
*.vcxproj.filters
*.in

src/test/testeverything/EverythingAddtests.hpp
src/test/testeverything/EverythingHeaders.hpp
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# NuPIC Core [![Build Status](https://travis-ci.org/numenta/nupic.core.png?branch=master)](https://travis-ci.org/numenta/nupic.core) [![Coverage Status](https://coveralls.io/repos/numenta/nupic.core/badge.png?branch=master)](https://coveralls.io/r/numenta/nupic.core?branch=master)
# NuPIC Core [![Build Status](https://travis-ci.org/rcrowder/nupic.core.png?branch=103-windows-build)](https://travis-ci.org/rcrowder/nupic.core)[![Build status](https://ci.appveyor.com/api/projects/status/g2vdotgyeh8nnpnn)](https://ci.appveyor.com/project/rcrowder/nupic-core)[![Coverage Status](https://coveralls.io/repos/numenta/nupic.core/badge.png?branch=master)](https://coveralls.io/r/numenta/nupic.core?branch=master)

This repository contains the C++ source code for the Numenta Platform for Intelligent Computing ([NuPIC](http://numenta.org/nupic.html)). It will eventually contain all algorithms for NuPIC, but is currently in a transition period. For details on building NuPIC within the python environment, please see http://github.com/numenta/nupic.

Expand Down Expand Up @@ -34,7 +34,7 @@ Important notes:

#### Generate the IDE solution:

* Open CMake executable.
* Open CMake-GUI executable.
* Specify the source folder (`$NUPIC_CORE/src`).
* Specify the build system folder (`$NUPIC_CORE/build/scripts`), i.e. where IDE solution will be created.
* Click `Generate`.
Expand All @@ -48,3 +48,4 @@ Important notes:
#### Run the tests:

* Run any `tests_*` project from your IDE (check `output` panel to see the results).

116 changes: 116 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,116 @@
#---------------------------------#
# general configuration #
#---------------------------------#

# version format
version: 1.0.{build}

# branches to build
branches:
# whitelist
only:
- 103-windows-build

# blacklist
except:
- master
- gh-pages

#---------------------------------#
# environment configuration #
#---------------------------------#

# Operating system (build VM template)
os: Windows Server 2012

# scripts that are called at very beginning, before repo cloning
init:
- git config --global core.autocrlf input
# - git submodule update --init --recursive

# clone directory
clone_folder: c:\projects\nupic-core

environment:
matrix:
# - COMPILER_FAMILY: GNU
- COMPILER_FAMILY: MSVC

# fast_finish: true
# allow_failures:
# - platform: x86
# configuration: Debug
# - platform: x64
# configuration: Debug


# scripts that run after cloning repository
install:
echo "Compiler family: %COMPILER_FAMILY%"
echo %PATH%

mkdir C:\projects\nupic-core\build\
mkdir C:\projects\nupic-core\build\scripts
cd C:\projects\nupic-core\build\scripts

IF "%COMPILER_FAMILY%" == "GNU" cmake C:\projects\nupic-core\src -G "MSYS Makefiles"
IF "%COMPILER_FAMILY%" == "MSVC" cmake C:\projects\nupic-core\src -G "Visual Studio 12"

# enable patching of AssemblyInfo.* files
assembly_info:
patch: true
file: AssemblyInfo.*
assembly_version: "1.0.{build}"
assembly_file_version: "{version}"
assembly_informational_version: "{version}"

#---------------------------------#
# build configuration #
#---------------------------------#

# build platform, i.e. x86, x64, Any CPU. This setting is optional.
platform:
- x86
# - x64

# build Configuration, i.e. Debug, Release, etc.
configuration:
# - Debug
- Release

# scripts to run before build
before_build:

build:
# project: NuPIC.core.sln # path to Visual Studio solution or project
# publish_wap: true # package Web Application Projects (WAP) for Web Deploy
# publish_wap_xcopy: true # package Web Application Projects (WAP) for XCopy deployment
# publish_azure: true # package Azure Cloud Service projects and push to artifacts
publish_nuget: true # package projects with .nuspec files and push to artifacts

# MSBuild verbosity level
#verbosity: normal #quiet|minimal|normal|detailed

# to run your custom scripts instead of automatic MSBuild
build_script:
cd C:\projects\nupic-core\build\scripts

IF "%COMPILER_FAMILY%" == "GNU" make
IF "%COMPILER_FAMILY%" == "MSVC" msbuild nupic_core.sln /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"

# scripts to run after build
after_build:
cd C:\projects\nupic-core\build\release
DIR
cd C:\projects\nupic-core\build\temp
DIR
cd C:\projects\nupic-core
PWD

#after_test:
# - ps: .\nuget\pack.ps1

#build: off
#test: off
deploy: off

32 changes: 32 additions & 0 deletions external/common/include/boost/boost/version.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// Boost version.hpp configuration header file ------------------------------//

// (C) Copyright John maddock 1999. Distributed under the Boost
// Software License, Version 1.0. (See accompanying file
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

// See http://www.boost.org/libs/config for documentation

#ifndef BOOST_VERSION_HPP
#define BOOST_VERSION_HPP

//
// Caution, this is the only boost header that is guarenteed
// to change with every boost release, including this header
// will cause a recompile every time a new boost version is
// released.
//
// BOOST_VERSION % 100 is the patch level
// BOOST_VERSION / 100 % 1000 is the minor version
// BOOST_VERSION / 100000 is the major version

#define BOOST_VERSION 105200

//
// BOOST_LIB_VERSION must be defined to be the same as BOOST_VERSION
// but as a *string* in the form "x_y[_z]" where x is the major version
// number, y is the minor version number, and z is the patch level if not 0.
// This is used by <config/auto_link.hpp> to select which library version to link to.

#define BOOST_LIB_VERSION "1_52"

#endif
3 changes: 2 additions & 1 deletion external/common/include/zconf.h
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,8 @@ typedef uLong FAR uLongf;
typedef Byte *voidp;
#endif

#if 1 /* HAVE_UNISTD_H -- this line is updated by ./configure */
/* https://mail-index.netbsd.org/tech-userlevel/1999/10/15/0000.html */
#if defined(HAVE_UNISTD_H) || defined(__NetBSD__)
# include <sys/types.h> /* for off_t */
# include <unistd.h> /* for SEEK_* and off_t */
# ifdef VMS
Expand Down
70 changes: 70 additions & 0 deletions external/win32/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
NuPIC Core external libraries
=============================

NuPIC Core depends on a number of pre-built external libraries which are
normally distributed with the source. However, since Windows is not an
officially supported platform, you will need to build the libraries yourself.

Use the following commands as a guide.

- Obtain the source for apr, apr-util, yaml, yaml-cpp, and
zlib.

apr-1.5.1 http://www.apache.org/dist/apr/ apr-1.5.1-win32-src.zip
apr-util-1.5.3 https://apr.apache.org/ apr-util-1.5.3-win32-src.zip
boost-1.52.0 http://www.boost.org/users/history/version_1_52_0.html boost_1_52_0.zip
yaml-0.1.5 http://pyyaml.org/wiki/LibYAML yaml-0.1.5.tar.gz
yaml-cpp-0.3.0 https://code.google.com/p/yaml-cpp/ yaml-cpp-0.3.0.tar.gz
zlib-1.2.8 http://www.zlib.net/ zlib-1.2.8.tar.gz
pcre-8.35 http://www.pcre.org/ pcre-8.35.zip

Extract them into $NUPIC_CORE/external/win32

Each one has a CMakeList.txt That allows for the use of the Windows version of CMake. The GUI version **must** be used to build Visual Studio project and solution files for all these external projects. The Windows version of CMake is the only versions that supports Visual Studio generators. Plus makes it easy to make needed tweaks to the build environments.

- Configure, and then Generate, each one with the generator that matches your installed IDE.

Open each solution file (.sln) in your VS IDE and build the Release configuration.

libapr-1 Link errors in apr_atomic with VS2013
http://mail-archives.apache.org/mod_mbox/apr-dev/201311.mbox/%3C1383702562.18420.YahooMailNeo@web122303.mail.ne1.yahoo.com%3E
Remove all "(apr_atomic_win32_ptr_fn)" unresolved external symbol Interlocked from apr_atomic.c in both apr-1 and libapr-1 libraries

Copy apr-1.5.1\include\arch to win32\include\apr-1\arch
Edit apr_arch_utf8.h and change the thre #include from
#include "apr.h"
#include "apr_lib.h"
#include "apr_errno.h"
to
#include "apr-1/apr.h"
#include "apr-1/apr_lib.h"
#include "apr-1/apr_errno.h"

yaml-cpp #include <algorithm> in src\ostream_wrapper.cpp
contrib\vstudio\vc11\x86\ZlibStatRelease\zlibstat.lib

zlib-1.2.8\contrib\vstudio\vc11

nupic.core\external\win32\apr-1.5.1>cmake -DBUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=..\include -P cmake_install.cmake

nupic.core\external\win32\pcre-8.35\cmake>cmake -DBUILD_TYPE=Release -DCMAK
E_INSTALL_PREFIX=..\..\include\pcre -P cmake_install.cmake



/GS /TC /analyze- /W3 /Zc:wchar_t /I"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3" /I"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3\include" /I"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3\include\private" /I"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\include\apr-1" /I"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3\xml\expat\lib" /Gm- /O2 /Ob2 /Fd"libaprutil-1.dir\Release\vc120.pdb" /fp:precise /D "WIN32" /D "_WINDOWS" /D "NDEBUG" /D "APU_DECLARE_EXPORT" /D "XML_STATIC" /D "CMAKE_INTDIR=\"Release\"" /D "libaprutil_1_EXPORTS" /D "_WINDLL" /D "_MBCS" /errorReport:prompt /WX- /Zc:forScope /Gd /Oy- /MD /Fa"Release/" /nologo /Fo"libaprutil-1.dir\Release\" /Fp"libaprutil-1.dir\Release\libaprutil-1.pch"

kernel32.lib;user32.lib;gdi32.lib;winspool.lib;shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;comdlg32.lib;advapi32.lib;C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\lib\apr-1.lib;Release\libexpat.lib

/machine:X86 /OUT:"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3\Release\libaprutil-1.dll" /MANIFEST /NXCOMPAT /PDB:"C:/Users/rcrowder/Dropbox/Private/github-Burt/nupic.core/external/win32/apr-util-1.5.3/Release/libaprutil-1.pdb" /DYNAMICBASE "kernel32.lib" "user32.lib" "gdi32.lib" "winspool.lib" "shell32.lib" "ole32.lib" "oleaut32.lib" "uuid.lib" "comdlg32.lib" "advapi32.lib" "C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\lib\apr-1.lib" "Release\libexpat.lib" /IMPLIB:"C:/Users/rcrowder/Dropbox/Private/github-Burt/nupic.core/external/win32/apr-util-1.5.3/Release/libaprutil-1.lib" /DLL /MACHINE:X86 /SAFESEH /INCREMENTAL:NO /PGD:"C:\Users\rcrowder\Dropbox\Private\github-Burt\nupic.core\external\win32\apr-util-1.5.3\Release\libaprutil-1.pgd" /SUBSYSTEM:CONSOLE /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /ManifestFile:"libaprutil-1.dir\Release\libaprutil-1.dll.intermediate.manifest" /ERRORREPORT:PROMPT /NOLOGO /TLBID:1

And, of course to build NuPIC Core itself:

```
mkdir -p $NUPIC_CORE/build/scripts
rm -rf $NUPIC_CORE/build/scripts/*
cd $NUPIC_CORE/build/scripts
cmake -DUSER_CXX_COMPILER=$CXX $NUPIC_CORE/src
VERBOSE=1 gmake
```

Loading