Skip to content

Commit e35522f

Browse files
committed
Conflicts: Dockerfile
2 parents f888846 + 709df98 commit e35522f

File tree

10 files changed

+58
-11
lines changed

10 files changed

+58
-11
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ charset = utf-8
1212

1313
# Tab indentation (no size specified)
1414
[Makefile]
15-
indent_style = space
15+
indent_style = tab
1616
indent_size = 2
1717

1818
# Indentation override for all JS under lib directory

.travis.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,20 @@
11
language: node_js
22

3+
os:
4+
- linux
5+
# - osx
6+
7+
matrix:
8+
allow_failures:
9+
- os: osx
10+
311
node_js:
4-
- '0.10'
5-
- '0.11'
612
- '0.12'
7-
- "iojs-v1.0.4"
13+
# - "iojs-v1.0.4"
14+
15+
sudo: required
16+
services:
17+
- docker
818

919
compiler: clang
1020

@@ -44,6 +54,8 @@ install:
4454
# test our module
4555
- npm test
4656
- node lib/opencv.js
57+
- docker build -t peterbraden/node-opencv-ubuntu-12-04 -f test/Dockerfile-ubuntu-12-04 .
58+
- docker build -t peterbraden/node-opencv-ubuntu-14-04 -f test/Dockerfile-ubuntu-14-04 .
4759

4860
before_script:
4961
- echo "Publishing native platform Binary Package? ->" $PUBLISH_BINARY

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
# 3) Test: docker run $USER/node-opencv node -e "console.log(require('opencv').version)"
66
#
77
# VERSION 0.2
8-
# DOCKER-VERSION 1.8.2
8+
# DOCKER-VERSION 8.1.2
99

10-
# update to 14.04, but lock versions at 12.04 for now
10+
# update to 14.04
1111
from ubuntu:14.04
1212
run apt-get update -qq
1313
run apt-get install -y software-properties-common python-software-properties

Makefile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
VERSION := $(shell node -e "console.log(require('./package.json').version)")
22

3-
.PHONY: default release smoke
4-
53
test:
64
npm test
5+
.PHONY: test
76

87
smoke:
98
npm install --build-from-source
109
node smoke/smoketest.js
1110
npm test
11+
.PHONY: smoke
1212

1313

1414
release:
@@ -32,3 +32,10 @@ release:
3232

3333
@echo "Publishing to NPM"
3434
@npm publish
35+
.PHONY: release
36+
37+
38+
travis-build:
39+
docker build -t peterbraden/node-opencv-ubuntu-12-04 -f test/Dockerfile-ubuntu-12-04 .
40+
docker build -t peterbraden/node-opencv-ubuntu-14-04 -f test/Dockerfile-ubuntu-14-04 .
41+
.PHONY: travis-build

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ detection. This can be used for face detection etc.
148148
mat.detectObject(haar_cascade_xml, opts, function(err, matches){})
149149
```
150150

151-
For convenience in face recognition, cv.FACE_CASCADE is a cascade that can be used for frontal face recognition.
151+
For convenience in face detection, cv.FACE_CASCADE is a cascade that can be used for frontal face detection.
152152

153153
Also:
154154

examples/salt.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/*
12
var cv = require('../lib/opencv');
23
34
cv.readImage("./files/mona.png", function(err, im) {
@@ -18,3 +19,4 @@ function salt(img, n) {
1819
img.set(y, x, 255);
1920
}
2021
}
22+
*/

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"url": "https://github.com/peterbraden/node-opencv.git"
3636
},
3737
"engines": {
38-
"node": ">=0.10"
38+
"node": ">=0.12"
3939
},
4040
"binary": {
4141
"module_name": "opencv",

src/FaceRecognizer.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#include "FaceRecognizer.h"
22
#include "OpenCV.h"
33

4-
#if ((CV_MAJOR_VERSION >= 2) && (CV_MINOR_VERSION >=4))
4+
#if ((CV_MAJOR_VERSION >= 2) && (CV_MINOR_VERSION >=4) && (CV_SUBMINOR_VERSION>=4))
55

66
#include "Matrix.h"
77
#include <nan.h>

test/Dockerfile-ubuntu-12-04

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# This is a dockerfile to test the build on ubuntu 12.04
2+
from ubuntu:12.04
3+
run apt-get update -qq
4+
run apt-get install -y software-properties-common python-software-properties
5+
run add-apt-repository -y ppa:kubuntu-ppa/backports
6+
run apt-get update
7+
run apt-get install -y libcv-dev libcvaux-dev libhighgui-dev libopencv-dev
8+
run curl -sL https://deb.nodesource.com/setup | bash -
9+
run apt-get install -y nodejs
10+
WORKDIR /root/node-opencv
11+
add . /root/node-opencv
12+
run npm install --unsafe-perm --build-from-source || cat npm-debug.log
13+
run make test

test/Dockerfile-ubuntu-14-04

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# This is a dockerfile to test the build on ubuntu 14.04
2+
from ubuntu:14.04
3+
run apt-get update -qq
4+
run apt-get install -y software-properties-common python-software-properties
5+
run add-apt-repository -y ppa:kubuntu-ppa/backports
6+
run apt-get update
7+
run apt-get install -y libcv-dev libcvaux-dev libhighgui-dev libopencv-dev
8+
run curl -sL https://deb.nodesource.com/setup | bash -
9+
run apt-get install -y nodejs
10+
WORKDIR /root/node-opencv
11+
add . /root/node-opencv
12+
run npm install --unsafe-perm --build-from-source || cat npm-debug.log
13+
run make test

0 commit comments

Comments
 (0)