Skip to content

Commit

Permalink
website - update installation instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
mario4tier committed Dec 21, 2024
1 parent dd5f9ce commit 3241ae3
Show file tree
Hide file tree
Showing 4 changed files with 119 additions and 15 deletions.
11 changes: 7 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,24 @@ Only notable changes are documented here. See GitHub commits for all changes.
## [0.6.0] 2024-12-24
### Added
- Packaging automation for various platforms, notably Windows 64 bits.
- Fix for very small inputs to TA functions (floating point epsilon problem).


### Fixed
- Autotools and CMakeLists.txt have been modernized.

- Fix for very small inputs to TA functions (floating point epsilon problem).
-
### Changed

- Static/Shared lib file names uses hyphen instead of underscore. This was needed for some package naming convention.
In other word, look for "ta-lib" instead of "ta_lib".

Example: when linking you now use "-lta-lib" instead of "-lta_lib".
Example: when linking you now specify "-lta-lib" instead of "-lta_lib".

- C/C++ headers are now under a "ta-lib" subdirectory. You may have to change your code accordingly.

Example: `#include <ta-lib/ta_libc.h>` instead of `#include <ta_libc.h>`
Best way to handle this is to add the headers path to your compiler (e.g. `-I/usr/local/include/ta-lib` for gcc).

Alternatively, you can modify your code to `#include <ta-lib/ta_libc.h>` instead of `#include <ta_libc.h>`

This change is for namespace best-practice for when TA-Lib is installed at the system level.

Expand Down
4 changes: 2 additions & 2 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ function call. </p>

<p>TA-Lib is multi-thread safe where it matters the most for performance: When calling any TA functions (e.g. TA_SMA, TA_RSI etc... )</p>

<p>One important caveat is the initialization of the "global setting" must first be all done from a single thread. That includes calls to:</p>
<p>One important caveat is the initialization of the "global settings" must first be done from a single thread. That includes calls to:</p>
<ul>
<li>TA_Initialize</li>
<li>TA_SetUnstablePeriod, TA_SetCompatibility</li>
Expand All @@ -458,6 +458,6 @@ function call. </p>

<p>One exception to the rule is TA_Shutdown() which must be called single threaded (typically from the only thread remaining prior to exit your application).</p>

<p>Note: TA-Lib uses C11 malloc/free which is a thread safe default on all modern platforms (Linux,Windows,Mac). Just keep that in mind if you modify the Makefile to link with a C runtime library other than the default installed on your system.</p>
<p>Note: TA-Lib assumes it is link to a thread safe malloc/free runtime library, which is the default on all modern platforms (Linux,Windows,Mac). In other word, safe with any compiler supporting C11 or more recent.</p>

</body>
115 changes: 108 additions & 7 deletions docs/install.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,114 @@
Check [https://pypi.org/project/TA-Lib](https://pypi.org/project/TA-Lib)
---
hide:
- toc
---
Latest release is [0.6.0 on Github](https://github.com/ta-lib/ta-lib-temp/releases/latest)

Read the "dependencies" section for various installation and troubleshooting tips.
- [Windows](#windows)
- [Executable Installer (recommended)](#executable-installer-recommended)
- [Binaries](#windows-binaries)
- [Build from source](#windows-build-from-source)

- [macOS](#macOS)
- [Homebrew (recommended)](#macOS-homebrew-recommended)
- [Build from source](#macOS-build-from-source)

**Source Package (with makefiles):**
- [Linux](#linux)
- [Debian packages](#linux-debian-packages)
- [Build from source](#linux-build-from-source)

- [ta-lib-0.4.0-src.tar.gz](https://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz)
## Windows

**Some variants:**
Only x86 64-bits binaries are distributed. Other windows platforms need to build from source.

### Executable Installer (recommended)

1. **Download** latest [ta-lib-0.6.0-windows-x86_64.msi](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib-0.6.0-windows-x86_64.msi)

2. **Run the Installer**:
- Double-click the downloaded `.msi` file.
- Follow the on-screen instructions.


To update, just repeat the installation (the older version is automatically uninstalled).

If you choose to uninstall, follow the [standard windows procedure](https://support.microsoft.com/en-us/windows/uninstall-or-remove-apps-and-programs-in-windows-4b55f974-2cc6-2d2b-d092-5905080eaf98)

If you prefer a non-interactive installation, you can use msiexec [from the command line](https://learn.microsoft.com/en-us/windows/win32/msi/standard-installer-command-line-options).


### Windows Binaries
This is a package with all the static/shared binaries and headers needed to bundle TA-Lib with your own application (eliminates having the user install TA-Lib separately).

Latest is [ta-lib-0.6.0-windows-x86_64.zip](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib-0.6.0-windows-x86_64.zip)

### Windows Build from Source

TODO

## macOS

### macOS Homebrew (recommended)

```bash
brew install ta-lib
```

See the [homebrew formula](https://formulae.brew.sh/formula/ta-lib) for the latest supported release and platforms.

### macOS Build from Source

TODO

## Linux

### Linux Debian Packages

Recommended for all debian-based distributions (e.g. Ubuntu, Mint...)

1. **Download** the `.deb` package matching your platform:

| Platform | Download |
|------------------------|--|
| Intel/AMD 64-bits | [ta-lib_0.6.0_amd64.deb](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib_0.6.0_amd64.deb) |
| ARM64 (e.g. Raspberry Pi)| [ta-lib_0.6.0_arm64.deb](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib_0.6.0_arm64.deb) |
| Intel/AMD 32-bits| [ta-lib_0.6.0_x86.deb](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib_0.6.0_x86.deb) |

2. **Install or Update**:
```bash
# For Intel/AMD (64 bits)
sudo dpkg -i ta-lib_0.6.0_amd64.deb
# or
sudo dpkg -i ta-lib_0.6.0_arm64.deb
# or
sudo dpkg -i ta-lib_0.6.0_x86.deb
```
If you choose to uninstall do:
```bash
sudo dpkg -r ta-lib
```

### Linux Build from Source

1. **Download** latest [ta-lib-0.6.0-src.tar.gz](https://github.com/ta-lib/ta-lib-temp/releases/download/v0.6.0/ta-lib-0.6.0-src.tar.gz)

2. **Extract the Tarball**:
```bash
tar -xzf ta-lib-0.6.0-src.tar.gz
cd ta-lib
```

3. **Build and Install**:
```bash
./configure
make
sudo make install
```

Follow the same procedure for an update (the older version is overwritten, no need to uninstall).

If you choose to uninstall do:
```bash
sudo make uninstall
```

- Java [ta-lib-0.4.0.jar](https://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0.jar)
- RPM [ta-lib-0.4.0-1.i386.rpm](https://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-1.i386.rpm)
4 changes: 2 additions & 2 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ markdown_extensions:
- def_list
- footnotes
- md_in_html
#- toc:
# permalink: true
- toc:
permalink: false
- pymdownx.arithmatex:
generic: true
- pymdownx.betterem:
Expand Down

0 comments on commit 3241ae3

Please sign in to comment.