File tree 5 files changed +19
-12
lines changed
5 files changed +19
-12
lines changed Original file line number Diff line number Diff line change 50
50
needs : check
51
51
52
52
- uses : r-lib/actions/check-r-package@v2
53
+ env :
54
+ MAKEFLAGS : -j4
Original file line number Diff line number Diff line change 1
1
Package: opencv
2
2
Type: Package
3
3
Title: Bindings to 'OpenCV' Computer Vision Library
4
- Version: 0.5.0
4
+ Version: 0.5.1
5
5
Authors@R: c(
6
6
person("Jeroen", "Ooms", role = c("aut", "cre"), email = "
[email protected] ",
7
7
comment = c(ORCID = "0000-0002-4035-0289")),
Original file line number Diff line number Diff line change 1
1
PKG_CPPFLAGS=@cflags@
2
2
PKG_LIBS=@libs@
3
+
4
+ all: cleanup
5
+
6
+ cleanup: $(SHLIB)
7
+ @rm -Rf ../.deps
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ $(info using $(PKG_CONFIG_NAME) from Rtools)
8
8
PKG_CPPFLAGS := $(shell $(PKG_CONFIG) --cflags $(PKG_CONFIG_NAME)) $(STATIC_CFLAGS)
9
9
OPENCVDATA := $(shell $(PKG_CONFIG) --variable=prefix $(PKG_CONFIG_NAME))/share/opencv4
10
10
else
11
- RWINLIB = ../windows /opencv
11
+ RWINLIB = ../.deps /opencv
12
12
PKG_CPPFLAGS = -I$(RWINLIB)/include/opencv4 $(STATIC_CFLAGS)
13
13
OLDLIBDIR = lib${subst gcc,,${COMPILED_BY}}${R_ARCH}
14
14
PKG_LIBS = \
@@ -21,16 +21,16 @@ PKG_LIBS = \
21
21
OPENCVDATA = $(RWINLIB)/share
22
22
endif
23
23
24
- all: $(SHLIB) copydata
24
+ all: copydata
25
25
26
- $(OBJECTS): $(RWINLIB)
26
+ $(OBJECTS): | $(RWINLIB)
27
27
28
28
$(RWINLIB):
29
29
"${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" "../tools/winlibs.R"
30
30
31
- copydata:
31
+ copydata: | $(RWINLIB)
32
32
rm -Rf ../inst/share && mkdir -p ../inst
33
33
cp -Rf $(OPENCVDATA) ../inst/share
34
34
35
- clean:
36
- rm -f $(SHLIB) $(OBJECTS )
35
+ cleanup: $(SHLIB)
36
+ @ rm -Rf $(RWINLIB )
Original file line number Diff line number Diff line change 1
- if (! file.exists(" ../windows /opencv/include/opencv4/opencv2/opencv.hpp" )){
2
- unlink(" ../windows " , recursive = TRUE )
1
+ if (! file.exists(" ../.deps /opencv/include/opencv4/opencv2/opencv.hpp" )){
2
+ unlink(" ../.deps " , recursive = TRUE )
3
3
url <- if (grepl(" aarch" , R.version $ platform )){
4
4
" https://github.com/r-windows/bundles/releases/download/opencv-4.8.1/opencv-4.8.1-clang-aarch64.tar.xz"
5
5
} else if (grepl(" clang" , Sys.getenv(' R_COMPILED_BY' ))){
@@ -10,9 +10,9 @@ if(!file.exists("../windows/opencv/include/opencv4/opencv2/opencv.hpp")){
10
10
" https://github.com/rwinlib/opencv/archive/refs/tags/v4.8.1.tar.gz"
11
11
}
12
12
download.file(url , basename(url ), quiet = TRUE )
13
- dir.create(" ../windows " , showWarnings = FALSE )
14
- untar(basename(url ), exdir = " ../windows " , tar = ' internal' )
13
+ dir.create(" ../.deps " , showWarnings = FALSE )
14
+ untar(basename(url ), exdir = " ../.deps " , tar = ' internal' )
15
15
unlink(basename(url ))
16
- setwd(" ../windows " )
16
+ setwd(" ../.deps " )
17
17
file.rename(list.files(), ' opencv' )
18
18
}
You can’t perform that action at this time.
0 commit comments