Skip to content
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

Update from idn11 to idn2 #218

Merged
merged 1 commit into from
Sep 9, 2022
Merged

Conversation

lolgab
Copy link
Contributor

@lolgab lolgab commented Sep 8, 2022

idn11 is not present in vcpkg's repository, which is one of the ways to static link applications with Scala Native using https://github.com/indoorvivants/sbt-vcpkg
Since idn2 is present and it's the newest version of the library, this PR updates sttp.model.internal.idn.CIdn to use idn2

idn11 is not present in vcpkg's repository, which is one of the ways
to static link applications with Scala Native using
https://github.com/indoorvivants/sbt-vcpkg
Since idn2 is present and it's the newest version of the library,
this PR updates `sttp.model.internal.idn.CIdn` to use idn2
@keynmol
Copy link

keynmol commented Sep 8, 2022

To add to this, idn1 and idn2 are not compatible, even such small usage as STTP model triggers a conflict:

[error] Undefined symbols for architecture arm64:
[error]   "_idn_free", referenced from:
[error]       __SM31sttp.model.internal.idn.IdnApi$D18toAscii$$anonfun$1L16java.lang.StringL29scala.scalanative.unsafe.ZoneL16java.lang.StringEPT31sttp.model.internal.idn.IdnApi$ in 3.ll.o
[error]   "_idna_strerror", referenced from:
[error]       __SM31sttp.model.internal.idn.IdnApi$D18toAscii$$anonfun$1L16java.lang.StringL29scala.scalanative.unsafe.ZoneL16java.lang.StringEPT31sttp.model.internal.idn.IdnApi$ in 3.ll.o
[error]   "_idna_to_ascii_8z", referenced from:
[error]       __SM31sttp.model.internal.idn.IdnApi$D18toAscii$$anonfun$1L16java.lang.StringL29scala.scalanative.unsafe.ZoneL16java.lang.StringEPT31sttp.model.internal.idn.IdnApi$ in 3.ll.o
[error] ld: symbol(s) not found for architecture arm64

So you can't just substitute one for another at link time.

@lolgab lolgab marked this pull request as ready for review September 9, 2022 08:12
@Pask423 Pask423 merged commit 6373296 into softwaremill:master Sep 9, 2022
@lolgab lolgab deleted the update-idn2 branch September 9, 2022 09:46
@lolgab
Copy link
Contributor Author

lolgab commented Sep 9, 2022

Can we have a release with this?
It would be great since it blocks the first Tapir Scala Native application in the world :)

@adamw
Copy link
Member

adamw commented Sep 10, 2022

@lolgab Yes released here: https://github.com/softwaremill/sttp-model/releases/tag/v1.5.2 :)

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

Successfully merging this pull request may close these issues.

4 participants