Skip to content

Commit cda39fe

Browse files
committed
doc update for macos arm64 support
1 parent c5d823d commit cda39fe

File tree

4 files changed

+21
-59
lines changed

4 files changed

+21
-59
lines changed

INSTALL.md

Lines changed: 10 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ DEALINGS IN THE SOFTWARE.
2525
2. [ibm_db Installation on z/OS](#inszos)
2626
3. [ibm_db installation on MacOS M1/M2 Chip System](#m1chip)
2727
4. [Troubleshooting Post Install Errors on MacOS](#troubleshooting)
28-
[SQL30081N Error](#sql30081n)
29-
[Symbol not found error or malloc error](#symbolerror)
28+
- [SQL30081N Error](#41-sql30081n-error)
29+
- [Symbol not found error or malloc error](#42-symbol-not-found-error-or-malloc-error)
3030

3131
## <a name="inslnx"></a> 1. Python-ibm_db Installation on Linux, AIX, zLinux, Windows and MacOS.
3232

@@ -326,15 +326,20 @@ print('ODBC Test end')
326326
327327
## <a name="m1chip"></a> 3. ibm_db installation on MacOS M1/M2 Chip System (arm64 architecture)
328328
**Important:
329-
> [email protected] onwards supports native installation on MacOS ARM64(M* Chip/Apple Silicon Chip) system using clidriver/dsdriver version 12.1.0.
329+
> [email protected] onwards supports native installation on MacOS ARM64(M* Chip/Apple Silicon Chip) system using clidriver/dsdriver version 12.1.0.
330+
> You need **db2connect v12.1 license** to connect to z/OS or iSeries server from M1 Chip system.
330331
331332
### Installation:
332333
Follow same steps as documented for [ibm_db Installation on Linux, AIX, zLinux, Widnows and MacOS.](#inslnx)
333334
334335
## <a name="troubleshooting"></a> 4. Troubleshooting Post Install Errors on MacOS
335-
<a name="sql30081n"></a> 4.1 SQL30081N Error
336+
337+
### 4.1 SQL30081N Error
338+
336339
* If connection fails with SQL30081N error: means `ibm_db` installation is correct and you need to provide correct connection string.
337-
<a name="symbolerror"></a> 4.2 Symbol not found error or malloc error
340+
341+
### 4.2 Symbol not found error or malloc error
342+
338343
* If `import ibm_db` fails with `Symbol not found: ___cxa_throw_bad_array_new_length` error or `malloc` error:
339344
You need to find the correct location of lib/gcc/12 directory and add it to DYLD_LIBRARY_PATH environment variable.
340345
Also, execute below commands from terminal with correct location of `lib/gcc/12/libstdc++.6.dylib` library.
@@ -352,25 +357,3 @@ install_name_tool -change /usr/local/lib/gcc/8/libstdc++.6.dylib /usr/local/Home
352357
i.e. change current path of `libstdc++.6.dylib` in `libdb2.dylib` library to the corrent path in your system. You can find the path of `libstdc++.6.dylib` in libdb2.dylib using the command : `otool -L libdb2.dylib`. Once you have the path of libstdc++.6.dylib, you need to change it using the commond: `install_name_tool -change <current path in libdb2.dylib> <actual path in your system> libdb2.dylib`
353358
Now run your test program and verify.
354359
355-
# M1 MAC Steps to Install IBM DB and Support Docker RUN
356-
## Installation Steps:
357-
### Install Podman / Docker:
358-
- **Podman:** Follow the instructions provided on the [official Podman website](https://podman.io/getting-started/installation) to install Podman on your M1 Mac.
359-
- **Docker:** Alternatively, you can install Docker using the native Apple Silicon version or the Rosetta-translated Intel version. Choose the method that best fits your requirements.
360-
### Install Intel Version of Python:
361-
1. Download and install the Intel version of Python 3.8 from the [official Python website](https://www.python.org/downloads/release/python-3810/).
362-
2. After installation, ensure that you set the interpreter to Python 3.8 in your development environment.
363-
## Configuration Steps:
364-
### Configure Docker for M1:
365-
- For M1 Macs, ensure compatibility by specifying the platform architecture during Docker build commands:
366-
docker build -t <image_name> . --platform=linux/amd64
367-
Alternatively, if you're using Podman:
368-
podman build -t <image_name> . --platform=linux/amd64
369-
### Build Docker Image (Intel):
370-
- If you're using an Intel Mac or running Docker with Rosetta translation, use the following command to build your Docker image:
371-
docker build -t <image_name> .
372-
## Additional Notes:
373-
- These steps are tailored for M1 Macs to ensure seamless installation and configuration of IBM DB and Docker support.
374-
- Verify that your Dockerfile and any dependencies are compatible with the specified platform architecture.
375-
Follow these steps carefully to set up IBM DB and Docker support on your M1 Mac environment. If you encounter any issues or have further questions, feel free to seek assistance from the community or relevant support channels.
376-
Happy coding!

README.md

Lines changed: 3 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Please follow detailed installation instructions as documented here: [ibm_db Ins
3030

3131
### For MacOS M1/M2/ Apple Silicon chip system
3232

33-
**MacOS with Silicon Chip** - Supported from next release onwards using v12.x clidriver.
33+
**MacOS with Silicon Chip** - Supported from v3.2.4 onwards using v12.x clidriver.
3434
**MacOS with Intel Chip** - Supported using v11.x clidriver only. By default v11.5.9 clidriver will get downloaded.
3535

3636
### Linux/Unix:
@@ -188,8 +188,6 @@ conda install -c conda-forge ibm_db
188188
|Windows | x64 | Yes | Latest |
189189
|Windows | x32 | Yes | Latest |
190190

191-
Install Intel/x64 version of python on M1 Chip system. Check [this](INSTALL.md#m1chip) link for detailed instructions.
192-
193191
## <a name="quick example"></a> Quick Example
194192
```python
195193
$ python
@@ -389,6 +387,8 @@ To suppress this error, Db2 server must be activated with db2connectactivate uti
389387
390388
- Db2connect license can be applied on database server or client side. A **db2connect license of version 11.5** is required for ibm_db.
391389
390+
- For MacOS M1/M2/M3 Chip System (ARM64 processor), **db2connect license of version 12.1** is required.
391+
392392
- For activating server side license, you can purchase either `Db2 Connect Unlimited Edition for System z®` or `Db2 Connect Unlimited Edition for System i®` license from IBM.
393393
394394
- Ask your DBA to run db2connectactivate utility on Server to activate db2connect license.
@@ -669,34 +669,10 @@ fail on version 8.x of Db2.
669669

670670
If trusted context is not set up, there will be two failures related to trusted context. When thick client has been used then additional three failures related to create, recreate DB.
671671

672-
`ibm_db` do not work with arm64 version of python, use x64 version.
673-
674-
675672
## Known Limitations for the Python wrapper
676673

677674
1. The rowcount for select statements can not be generated.
678675
2. Some warnings from the drivers are not caught by the wrapper.
679676
As such these might go unnoticed.
680677

681-
# M1 MAC Steps to Install IBM DB and Support Docker RUN
682-
## Installation Steps:
683-
### Install Podman / Docker:
684-
- **Podman:** Follow the instructions provided on the [official Podman website](https://podman.io/getting-started/installation) to install Podman on your M1 Mac.
685-
- **Docker:** Alternatively, you can install Docker using the native Apple Silicon version or the Rosetta-translated Intel version. Choose the method that best fits your requirements.
686-
### Install Intel Version of Python:
687-
1. Download and install the Intel version of Python 3.8 from the [official Python website](https://www.python.org/downloads/release/python-3810/).
688-
2. After installation, ensure that you set the interpreter to Python 3.8 in your development environment.
689-
## Configuration Steps:
690-
### Configure Docker for M1:
691-
- For M1 Macs, ensure compatibility by specifying the platform architecture during Docker build commands:
692-
docker build -t <image_name> . --platform=linux/amd64
693-
Alternatively, if you're using Podman:
694-
podman build -t <image_name> . --platform=linux/amd64
695-
### Build Docker Image (Intel):
696-
- If you're using an Intel Mac or running Docker with Rosetta translation, use the following command to build your Docker image:
697-
docker build -t <image_name> .
698-
## Additional Notes:
699-
- These steps are tailored for M1 Macs to ensure seamless installation and configuration of IBM DB and Docker support.
700-
- Verify that your Dockerfile and any dependencies are compatible with the specified platform architecture.
701-
Follow these steps carefully to set up IBM DB and Docker support on your M1 Mac environment. If you encounter any issues or have further questions, feel free to seek assistance from the community or relevant support channels.
702678
Happy coding!

ibm_db.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
+--------------------------------------------------------------------------+
2323
*/
2424

25-
#define MODULE_RELEASE "3.2.3"
25+
#define MODULE_RELEASE "3.2.4"
2626

2727
#include <Python.h>
2828
#include <datetime.h>

setup.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
from setuptools.command.install import install
3232

3333
PACKAGE = 'ibm_db'
34-
VERSION = '3.2.3'
34+
VERSION = '3.2.4'
3535
LICENSE = 'Apache License 2.0'
3636
readme = os.path.join(os.path.dirname(__file__),'README.md')
3737

@@ -512,6 +512,7 @@ def print_exception( e, url):
512512
_checkGcc()
513513
_checkPythonHeaderFile()
514514

515+
#'Operating System :: z/OS', pypi upload fails with error - Not a valid classifier
515516
setup( name = PACKAGE,
516517
version = VERSION,
517518
license = LICENSE,
@@ -525,10 +526,12 @@ def print_exception( e, url):
525526
'Intended Audience :: Developers',
526527
'License :: OSI Approved :: Apache Software License',
527528
'Operating System :: Microsoft :: Windows :: Windows 10',
529+
'Operating System :: Microsoft :: Windows :: Windows 11',
528530
'Operating System :: Unix',
529-
'Operating System :: Linux',
530-
'Operating System :: MacOS-x64',
531-
'Operating System :: z/OS',
531+
'Operating System :: POSIX :: AIX',
532+
'Operating System :: POSIX :: Linux',
533+
'Operating System :: MacOS',
534+
'Operating System :: MacOS :: MacOS X',
532535
'Programming Language :: Python',
533536
'Programming Language :: Python :: 3.7',
534537
'Programming Language :: Python :: 3.8',

0 commit comments

Comments
 (0)