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

Unnecessary Rebuilds with yarn #34

Open
dsanders11 opened this issue Jun 13, 2019 · 3 comments
Open

Unnecessary Rebuilds with yarn #34

dsanders11 opened this issue Jun 13, 2019 · 3 comments

Comments

@dsanders11
Copy link

This one is strange and I can't quite figure it out, but I'm seeing opencv-build needing to be rebuilt a lot as I do things with yarn. It's version 0.1.3 so it has the logic to prevent unnecessary rebuilds, and sometimes that works, but sometimes it doesn't.

@justadudewhohacks, have you tested much with yarn, or only npm? Specifically I'm using a yarn workspace where there's sub-projects. Perhaps that's causing confusion on finding the files? This is on macOS, with the latest version of yarn.

@justadudewhohacks
Copy link
Owner

Personally I am not using yarn, but if you can figure out the reason for that and if this is something we can fix let me know!

@JCMais
Copy link

JCMais commented Nov 7, 2019

Probably related yarnpkg/yarn#932 (comment)

Per yarnpkg/yarn#5680 (comment), If the package deletes/modifies files that were bundled with it, yarn will see that the hash has changed and then will reinstall the package.

@JCMais
Copy link

JCMais commented Nov 8, 2019

As a workaround to this issue, I copied the opencv-build folder somewhere else and exported the following environment variables:

OPENCV4NODEJS_DISABLE_AUTOBUILD=1
OPENCV_LIB_DIR='path-to-opencv-build\\opencv\\build\\lib\\Release'
OPENCV_INCLUDE_DIR='path-to-opencv-build\\opencv\\build\\include'
OPENCV_BIN_DIR='path-to-opencv-build\\opencv\\build\\bin\\Release'

Keep in mind those paths are for Windows.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants