-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
GulajavaMinistudio/yarn
#206Description
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Some prebuilt packages (sse4_crc32, for example) in offline mirror don't actually contain prebuilt binaries. I'm guessing yarn fails to package built binaries maybe due to the lack of lifecycle scripts or something else entirely.
If the current behavior is a bug, please provide the steps to reproduce.
Steps to reproduce:
- Be
yarn 1.6.0+ - Make a
.yarnrc with
yarn-offline-mirror "./npm-packages-offline-cache"
experimental-pack-script-packages-in-mirror true
yarn add '[email protected]'- Observe that it's working:
❯ node -p "require('sse4_crc32')"
{ isHardwareCrcSupported: [Function: isHardwareCrcSupported],
calculateInSoftware: [Function: swCrc32c],
calculateOnHardware: [Function: hwCrc32c],
CRC32: [Function: Crc32C],
calculate: [Function: hwCrc32c] }
- Observe the prebuilt tarball:
❯ ls -l npm-packages-offline-cache/prebuilt/
total 24
-rw-r--r-- 1 aleksey staff 9059 Apr 29 18:44 sse4_crc32-v4.1.1-darwin-x64-57.tgz
- Observe that
sse4_crc32-v4.1.1-darwin-x64-57.tgzdoes NOT contain the build target:
tar -xf sse4_crc32-v4.1.1-darwin-x64-57.tgz && find package -name '*.node'
rm -rf node_modules && yarn --offlinenode -p "require('sse4_crc32')"now fails:
Error: Could not locate the bindings file. Tried:
What is the expected behavior?
The .node files should be packed and then unpacked in the prebuilt tarballs.
Please mention your node.js, yarn and operating system version.
Node 8.11.1
Darwin
Yarn Master