|
| 1 | +This has a new binding scheme in building OpenSSL-1.1.0 library with |
| 2 | +Node.js. OpenSSL-1.1.0 uses a new build system with `Perl` for various |
| 3 | +supported platforms. See `openssl/Configurations/README` and |
| 4 | +`openssl/Configurations/README.design` in the OpenSSL source for |
| 5 | +details. |
| 6 | + |
| 7 | +In order to build OpenSSL library without `Perl` in the build of Node.js |
| 8 | +for various supported platforms, platform dependent files (e.g. asm |
| 9 | +and header files ) are pre-generated and stored into the |
| 10 | +`config/archs` directory. |
| 11 | + |
| 12 | +- `config/Makefile` and `config/generate_gypi.pl` |
| 13 | + |
| 14 | + Makefile has supported platform list and generates and copies |
| 15 | + platform dependent files (e.g. asm files) into arch directory with |
| 16 | + `generate_gypi.pl`. Platform dependent gypi files also created |
| 17 | + obtaining build information from `configdata.pm` that is generated |
| 18 | + with `Configure` in the OpenSSL build system. |
| 19 | + |
| 20 | + For Windows, `Configure` generates `makefile` that is only available |
| 21 | + to `nmake` command. `config/Makefile_VC-WIN32` and |
| 22 | + `config/Makefile_VC-WIN64A` are made by hand for the use of GNU |
| 23 | + make. If `makefile` rules or targets are changed in the version up |
| 24 | + of OpenSSL, they should be also updated. |
| 25 | + |
| 26 | +- gyp and gypi files (`openssl*.{gyp,gypi}`) |
| 27 | + |
| 28 | + `openssl.gyp` has two targets of openssl and openssl-cli referred |
| 29 | + from `node.gyp`. They include asm and no_asm gypi files with arch |
| 30 | + dependent gypi according to its build options and platforms. The |
| 31 | + gyp data which is common with asm and no_asm are stored in |
| 32 | + `openssl_common.gypi`. |
| 33 | + |
| 34 | +- header files (`config/*.{h,h.tmpl}`) |
| 35 | + |
| 36 | + `bn_conf.h`, `dso_conf.h` and `opensslconf.h` are platform dependent |
| 37 | + in the OpenSSL sources. They are replaced with `config/*.h.tmpl` |
| 38 | + files to include the file in the `../../../config/` and referred to |
| 39 | + each arch file that depends on asm and no-asm option. |
| 40 | + |
| 41 | +### Supported architectures for use of ASM |
| 42 | + |
| 43 | +Here is a list of supported architectures for use of ASM in OpenSSL. |
| 44 | + |
| 45 | + | --dest-os | --dest-cpu | OpenSSL target arch | CI | |
| 46 | + | --------- | ---------- | -------------------- | --- | |
| 47 | + | aix | ppc | aix-gcc | o | |
| 48 | + | aix | ppc64 | aix64-gcc | o | |
| 49 | + | linux | ia32 | linux-elf | o | |
| 50 | + | linux | x32 | linux-x32 | - | |
| 51 | + | linux | x64 | linux-x86_64 | o | |
| 52 | + | linux | arm | linux-armv4 | o | |
| 53 | + | linux | arm64 | linux-aarch64 | o | |
| 54 | + | linux | ppc | linux-ppc | o | |
| 55 | + | linux | ppc64 | linux-ppc64 | o | |
| 56 | + | linux | ppc64(*1) | linux-ppc64le | o | |
| 57 | + | linux | s390 | linux32-s390x | o | |
| 58 | + | linux | s390x | linux64-s390x | o | |
| 59 | + | mac | ia32 | darwin-i386-cc | - | |
| 60 | + | mac | x64 | darwin64-x86-cc | o | |
| 61 | + | win | ia32 | VC-WIN32 | - | |
| 62 | + | win | x64 | VC-WIN64A | o | |
| 63 | + | solaris | ia32 | solaris-x86-gcc | o | |
| 64 | + | solaris | x64 | solaris64-x86_64-gcc | o | |
| 65 | + | freebsd | ia32 | BSD-x86 | - | |
| 66 | + | freebsd | x64 | BSD-x86_64 | o | |
| 67 | + | openbsd | ia32 | BSD-x86 | - | |
| 68 | + | openbsd | x64 | BSD-x86_64 | - | |
| 69 | + | others | others | linux-elf | - | |
| 70 | + |
| 71 | +(*1: This needs to be configured with the variable of node_byteorder: |
| 72 | +little) |
| 73 | + |
| 74 | +These are listed in [config/Makefile](config/Makefile). |
| 75 | +Please refer [config/opensslconf_asm.h](config/opensslconf_asm.h) for details. |
| 76 | + |
| 77 | +### Upgrading OpenSSL |
| 78 | + |
| 79 | +Please refer [config/README.md](config/README.md). |
0 commit comments