Skip to content

Commit

Permalink
Merge pull request #34 from open-vcpkg/psycopg2
Browse files Browse the repository at this point in the history
[py-psycopg2] New port
  • Loading branch information
m-kuhn authored Jun 28, 2024
2 parents c87f511 + bd9ffab commit 392535a
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:
- name: 🌋 Build
run: |
.\vcpkg\vcpkg.exe install --overlay-ports="${{ github.workspace }}/ports" --triplet=${{ matrix.triplet }} --x-buildtrees-root=C:/vcpkg-build py-pyqt6 py-pyyaml py-numpy gdal[python] py-qscintilla
.\vcpkg\vcpkg.exe install --overlay-ports="${{ github.workspace }}/ports" --triplet=${{ matrix.triplet }} --x-buildtrees-root=C:/vcpkg-build py-pyqt6 py-pyyaml py-numpy gdal[python] py-qscintilla py-psycopg2
- name: 📑 Upload logs
uses: actions/upload-artifact@v4
Expand Down
14 changes: 14 additions & 0 deletions ports/py-psycopg2/portfile.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
vcpkg_from_pythonhosted(
OUT_SOURCE_PATH SOURCE_PATH
PACKAGE_NAME psycopg2
VERSION ${VERSION}
SHA512 a691fd09762221e854861dedce37b05e5354e0701feea470a6d5046960056ef02a8c9ecfa751adeba485271ea7d5834643b7d3a3c3f3270087f5ed9c68509f5f
)

vcpkg_add_to_path("${CURRENT_INSTALLED_DIR}/tools/libpq/bin")

vcpkg_python_build_and_install_wheel(SOURCE_PATH "${SOURCE_PATH}" OPTIONS -x)

vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")

set(VCPKG_POLICY_EMPTY_INCLUDE_FOLDER enabled)
18 changes: 18 additions & 0 deletions ports/py-psycopg2/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"name": "py-psycopg2",
"version": "2.9.9",
"description": "Python-PostgreSQL Database Adapter",
"homepage": "https://psycopg.org/",
"dependencies": [
{
"name": "py-setuptools",
"host": true
},
"python3",
"libpq",
{
"name": "vcpkg-python-scripts",
"host": true
}
]
}

0 comments on commit 392535a

Please sign in to comment.