Skip to content

libpq: update mingw static libraries patch to work with 15.4 #25453

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

scandyna
Copy link
Contributor

Summary

Changes to recipe: libpq/15 (not the recipe, but a patch)

Motivation

See #25282

Building libpq/15.4 static on MinGW produces an empty libpq.a library. When used, linking fails with undefined references.

Details

The patches/15/001-mingw-build-static-libraries.patch was created to fix MinGW static builds and worked for erlier versions of libpq, but fails for 15.4.
Digging in what this patch does, I found a missing block that also has to be patched in the Makefile.shlib, starting at line 358:

# Win32 case

# See notes in src/backend/parser/Makefile about the following two rules
$(stlib): $(shlib)
	touch $@

With this PR, this block will be replaced with:

# Win32 case

# See notes in src/backend/parser/Makefile about the following two rules
$(stlib): $(OBJS) | $(SHLIB_PREREQS)
	rm -f $@
	$(LINK.static) $@ $^
	$(RANLIB) $@
	touch $@

I ran the tests for some configurations:
https://gitlab.com/scandyna/conan-center-index-partialbasicci-sandbox/-/pipelines/1474053728

Note that for MSVC, the test_v1_package fails. Probably something missing in my environment (I don't use the cmake generator anymore).

…rk with 15.4

Building libpq/15.4 static on MinGW produces an empty libpq.a librariy.
When used, linking fails with undefined references.
The updated patches/15/001-mingw-build-static-libraries.patch fixes that.
@conan-center-bot

This comment has been minimized.

@scandyna
Copy link
Contributor Author

scandyna commented Oct 1, 2024

license/cla is still pending:

license/cla Expected — Waiting for status to be reported

I got here yesterday, and today, to agree again.
Just after, if I go to the same page, or here, it tells me:

You have agreed to the CLA for conan-io/conan-center-index

Is there something I should do ?

@conan-center-bot
Copy link
Collaborator

Conan v1 pipeline ✔️

Warning

Conan Center will stop receiving updates for Conan 1.x packages soon - please see announcement.

All green in build 2 (a0c656667d2c92e28c40e63a39de54df8df19397):

  • libpq/15.4:
    Built 20 packages out of 22 (All logs)

  • libpq/15.5:
    Built 20 packages out of 22 (All logs)

  • libpq/14.9:
    Built 20 packages out of 22 (All logs)

  • libpq/13.12:
    Built 20 packages out of 22 (All logs)

  • libpq/15.3:
    Built 20 packages out of 22 (All logs)

  • libpq/11.21:
    Built 20 packages out of 22 (All logs)

  • libpq/12.16:
    Built 20 packages out of 22 (All logs)

  • libpq/9.6.24:
    Built 20 packages out of 22 (All logs)

  • libpq/10.23:
    Built 20 packages out of 22 (All logs)


Conan v2 pipeline ✔️

Note: Conan v2 builds are now mandatory. Please read our discussion about it.

All green in build 2 (a0c656667d2c92e28c40e63a39de54df8df19397):

  • libpq/13.12:
    All packages built successfully! (All logs)

  • libpq/15.5:
    All packages built successfully! (All logs)

  • libpq/15.4:
    All packages built successfully! (All logs)

  • libpq/15.3:
    All packages built successfully! (All logs)

  • libpq/12.16:
    All packages built successfully! (All logs)

  • libpq/10.23:
    All packages built successfully! (All logs)

  • libpq/11.21:
    All packages built successfully! (All logs)

  • libpq/14.9:
    All packages built successfully! (All logs)

  • libpq/9.6.24:
    All packages built successfully! (All logs)

@jcar87 jcar87 self-assigned this Oct 16, 2024
@ErniGH
Copy link
Contributor

ErniGH commented Nov 20, 2024

So sorry for the noise here

@ErniGH
Copy link
Contributor

ErniGH commented Feb 11, 2025

Hello @scandyna,

I'm sorry for not getting back to you sooner. I was looking at this new patch. I’ve tried to connect it with some upstream issue or thread discussing the matter, but I haven’t found anything. Could you help me understand the origin of these changes? I appreciate any help you can provide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants