@@ -853,6 +853,8 @@ To use python-oracledb without the cryptography package:
853
853
- Add a call to :meth: `oracledb.init_oracle_client() ` in your application, see
854
854
:ref: `enablingthick `.
855
855
856
+ .. _installsrc :
857
+
856
858
Installing from Source Code
857
859
===========================
858
860
@@ -866,6 +868,16 @@ code:
866
868
867
869
- C Compiler: A C99 compiler is needed.
868
870
871
+ **Optional Compilation Arguments **
872
+
873
+ Before building python-oracledb, the optional environment variable
874
+ ``PYO_COMPILE_ARGS `` can be set to change the compilation arguments. For
875
+ example, to build stripped binaries on Linux, first set::
876
+
877
+ export PYO_COMPILE_ARGS='-g0'
878
+
879
+ After this, one of the following installation methods can be used.
880
+
869
881
.. _installgh :
870
882
871
883
Install Using GitHub
@@ -879,8 +891,20 @@ commands::
879
891
python setup.py build
880
892
python setup.py install
881
893
894
+ If you do not have access to system directories, the ``--user `` option can be
895
+ used to install into a local directory::
896
+
897
+ python setup.py install --user
898
+
899
+ Note that if you download a source zip file directly from GitHub then you will
900
+ also need to download an `ODPI-C <https://github.com/oracle/odpi >`__ source zip
901
+ file and put the extracted contents inside the "odpi" subdirectory, for example
902
+ in "python-oracledb-main/src/oracledb/impl/thick/odpi".
903
+
882
904
.. _whlpkg :
883
905
906
+ **Creating a package for installation **
907
+
884
908
To create a package suitable for installing on other computers, run the
885
909
following commands::
886
910
@@ -896,15 +920,6 @@ version. To install the wheel, run::
896
920
897
921
python -m pip install oracledb-2.2.0-cp312-cp312-macosx_10_9_universal2.whl
898
922
899
- If you do not have access to system directories, the ``--user `` option can be
900
- used to install into a local directory::
901
-
902
- python setup.py install --user
903
-
904
- Note that if you download a source zip file directly from GitHub then you will
905
- also need to download an `ODPI-C <https://github.com/oracle/odpi >`__ source zip
906
- file and put the extracted contents inside the "odpi" subdirectory, for example
907
- in "python-oracledb-main/src/oracledb/impl/thick/odpi".
908
923
909
924
Install Using opensource.oracle.com
910
925
-----------------------------------
0 commit comments