Skip to content
This repository has been archived by the owner on Jan 13, 2024. It is now read-only.

Commit

Permalink
deployFiles suppresses addon warning. it provides it's own
Browse files Browse the repository at this point in the history
  • Loading branch information
igorklopov committed Aug 4, 2017
1 parent 9f50ec9 commit 3e79f4c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
11 changes: 8 additions & 3 deletions lib/walker.js
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@ class Walker {

const { deployFiles } = pkgConfig;
if (deployFiles) {
marker.hasDeployFiles = true;
for (const deployFile of deployFiles) {
log.warn('Cannot include file %1 into executable.', [
'The file must be distributed with executable as %2.',
Expand Down Expand Up @@ -521,9 +522,13 @@ class Walker {
});

if (isDotNODE(record.file)) {
log.warn('Cannot include addon %1 into executable.', [
'The addon must be distributed with executable as %2.',
record.file, 'path-to-executable/' + path.basename(record.file) ]);
// provide explicit deployFiles to override
// native addon deployment place. see 'sharp'
if (!record.marker.hasDeployFiles) {
log.warn('Cannot include addon %1 into executable.', [
'The addon must be distributed with executable as %2.',
record.file, 'path-to-executable/' + path.basename(record.file) ]);
}
return; // discard
}

Expand Down
2 changes: 1 addition & 1 deletion prelude/bootstrap.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ function projectToFilesystem (f) {
xpdn,
uplevel,
relative
))
));
});
});
return results;
Expand Down

0 comments on commit 3e79f4c

Please sign in to comment.