|
1 | 1 | ## Building wolfCLU |
| 2 | + |
| 3 | +### Building on *NIX |
2 | 4 | To build wolfCLU first build wolfSSL with the --enable-wolfclu flag. An example of this would be: |
3 | 5 |
|
4 | 6 | ``` |
@@ -26,4 +28,38 @@ cd wolfclu |
26 | 28 | ./configure --with-wolfssl=/path/to/wolfssl/install |
27 | 29 | make |
28 | 30 | sudo make install |
29 | | -``` |
| 31 | +``` |
| 32 | + |
| 33 | +Run `make check` to run unit tests. |
| 34 | + |
| 35 | +## Building on Windows |
| 36 | + |
| 37 | +wolfCLU can also be built with its Visual Studios solution, wolfclu.sln. The solution provides both Debug and Release builds of Dynamic 32- or 64-bit libraries. The file `user_settings.h` should be used in the wolfSSL build to configure it. |
| 38 | + |
| 39 | +The file `wolfclu\ide\winvs\user_settings.h` contains the settings used to configure wolfSSL with the appropriate settings. This file must be copied from the directory `wolfclu\ide\winvs` to `wolfssl\IDE\WIN`. You can then build wolfSSL with support for wolfCLU. |
| 40 | + |
| 41 | +Before building wolfCLU, Make sure you have the same architecture (Win32 or x64) selected as used in wolfSSL. |
| 42 | + |
| 43 | +This project assumes that the wolfSSH and wolfSSL source directories |
| 44 | +are installed side-by-side and do not have the version number in their |
| 45 | +names: |
| 46 | +``` |
| 47 | + Projects\ |
| 48 | + wolfclu\ |
| 49 | + wolfssl\ |
| 50 | +``` |
| 51 | + |
| 52 | +Building wolfCLU a release configuration will generate `wolfssl.exe` in the |
| 53 | +`Release\Win32` or `Release\x64` directory. |
| 54 | + |
| 55 | +#### Running Unit Tests |
| 56 | + |
| 57 | +To run the shell-script unit tests, you will need either the `sh` or `bash` |
| 58 | +commands, both of which come with a Git installation on Windows (although you |
| 59 | +may have to add them to the PATH). |
| 60 | + |
| 61 | +1. Copy the `wolfssl.exe` to the root directory of wolfclu. |
| 62 | +2. Modify the `run` function (as well as `run_fail`, if present) of the desired |
| 63 | +unit test to run `./wolfssl.exe $1` instead of `./wolfssl $1`. |
| 64 | +3. In your terminal, run `sh <desired_unit_test>` from the root directory. For |
| 65 | +instance, to run the hash unit tests, run `sh tests\hash\hash-test.sh`. |
0 commit comments