Skip to content
This repository was archived by the owner on Jan 24, 2025. It is now read-only.

Commit 8ddcbef

Browse files
jeffesquivelsstyppo
authored andcommitted
Generate binary addon for SSE2 too
1 parent d48f899 commit 8ddcbef

File tree

3 files changed

+42
-1
lines changed

3 files changed

+42
-1
lines changed

binding.gyp

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,46 @@
8383
]
8484
}
8585
},
86+
{
87+
"target_name": "nimiq_node_sse2",
88+
"sources": [
89+
"src/native/argon2.c",
90+
"src/native/blake2/blake2b.c",
91+
"src/native/core.c",
92+
"src/native/encoding.c",
93+
"src/native/nimiq_native.c",
94+
"src/native/ref.c",
95+
"src/native/sha256.c",
96+
"src/native/ed25519/collective.c",
97+
"src/native/ed25519/fe.c",
98+
"src/native/ed25519/ge.c",
99+
"src/native/ed25519/keypair.c",
100+
"src/native/ed25519/memory.c",
101+
"src/native/ed25519/sc.c",
102+
"src/native/ed25519/sha512.c",
103+
"src/native/ed25519/sign.c",
104+
"src/native/ed25519/verify.c",
105+
"src/native/nimiq_node.cc"
106+
],
107+
"defines": [
108+
"ARGON2_NO_THREADS"
109+
],
110+
"include_dirs": [
111+
"<!(node -e \"require('nan')\")",
112+
"src/native"
113+
],
114+
"cflags_c": [
115+
"-std=c99",
116+
"-msse",
117+
"-msse2",
118+
],
119+
"xcode_settings": {
120+
"OTHER_CFLAGS": [
121+
"-msse",
122+
"-msse2",
123+
]
124+
}
125+
},
86126
{
87127
"target_name": "nimiq_node_avx",
88128
"sources": [

doc/linux-packaging.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Note: creating deb packages only has been tested extensively on Ubuntu and Debia
1616
#### Fedora/CentOS/RHEL (RPM package format)
1717

1818
1. Make sure you have `rpm-build` installed (otherwise, install it with `yum` or `dnf`).
19-
2. Run `PACKAGING=1 yarn `
19+
2. Run `PACKAGING=1 yarn`
2020
3. Then run `yarn run build-rpm`.
2121
4. The RPM package will be located in the `dist/` directory.
2222

gulpfile.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -593,6 +593,7 @@ const RELEASE_LIB = [
593593

594594
const RELEASE_ADDONS = [
595595
'build/Release/nimiq_node_compat.node',
596+
'build/Release/nimiq_node_sse2.node',
596597
'build/Release/nimiq_node_avx.node',
597598
'build/Release/nimiq_node_avx2.node',
598599
'build/Release/nimiq_node_avx512f.node'

0 commit comments

Comments
 (0)