Bug 241663

Summary: lang/ponyc: Update to 0.33.0
Product: Ports & Packages Reporter: Tobias Kortkamp <tobik>
Component: Individual Port(s)Assignee: Tobias Kortkamp <tobik>
Status: Closed FIXED    
Severity: Affects Only Me CC: val
Priority: --- Flags: bugzilla: maintainer-feedback? (val)
Version: Latest   
Hardware: Any   
OS: Any   
URL: https://github.com/ponylang/ponyc/releases/tag/0.33.0
Attachments:
Description Flags
ponyc.diff val: maintainer-approval+

Description Tobias Kortkamp freebsd_committer freebsd_triage 2019-11-02 05:55:15 UTC
Created attachment 208787 [details]
ponyc.diff

Small update to ponyc 0.33.0

This also adds a new STATIC default option to link with LLVM
statically.  Upstream now supports it and we can avoid having to
have llvm70 installed at runtime just for ponyc.  Installed size
goes up from 6 MiB to 50 MiB which I think is acceptable.

patch-Makefile-ponyc is to avoid the following problem at runtime
when llvm70 is not installed i.e. with STATIC=on:

Warning: environment variable $CC undefined, using /usr/local/bin/clang70 as the linker
Error:
unable to link: /usr/local/bin/clang70 -o ./helloworld -O3 -march=core2 -mcx16   ./helloworld.o -L"/usr/local/lib/pony/0.33.0/bin/" -Wl,-rpath,"/usr/local/lib/pony/0.33.0/bin/" -L"/usr/local/lib/pony/0.33.0/bin/../lib/core2" -Wl,-rpath,"/usr/local/lib/pony/0.33.0/bin/../lib/core2" -L"/usr/local/lib/pony/0.33.0/bin/../packages" -Wl,-rpath,"/usr/local/lib/pony/0.33.0/bin/../packages" -L"/usr/local/lib" -Wl,-rpath,"/usr/local/lib" -Wl,--start-group -Wl,--end-group  -lpthread  -lponyrt  -lm -lexecinfo

PONY_COMPILER seems to only be used to invoke the linker, so hardcoding
/usr/bin/cc as a workaround is hopefully fine.  This is mostly a problem
because CC is overwritten in the port.

Builds fine in Poudriere on 11.3 amd64, 12.0 amd64.
Comment 1 Val Packett 2019-11-04 19:27:51 UTC
Comment on attachment 208787 [details]
ponyc.diff

I'd rather not default to STATIC as long as dynamic linking is supported. But keep the CC patch.
Comment 2 commit-hook freebsd_committer freebsd_triage 2019-11-04 23:40:42 UTC
A commit references this bug:

Author: tobik
Date: Mon Nov  4 23:39:56 UTC 2019
New revision: 516751
URL: https://svnweb.freebsd.org/changeset/ports/516751

Log:
  lang/ponyc: Update to 0.33.0

  - Add new option STATIC to link ponyc statically with llvm70

  Changes:	https://github.com/ponylang/ponyc/releases/tag/0.33.0
  PR:		241663
  Approved by:	greg@unrelenting.technology (maintainer)

Changes:
  head/lang/ponyc/Makefile
  head/lang/ponyc/distinfo
  head/lang/ponyc/files/
  head/lang/ponyc/files/patch-Makefile-ponyc
  head/lang/ponyc/pkg-plist
Comment 3 commit-hook freebsd_committer freebsd_triage 2019-11-04 23:44:44 UTC
A commit references this bug:

Author: tobik
Date: Mon Nov  4 23:43:46 UTC 2019
New revision: 516752
URL: https://svnweb.freebsd.org/changeset/ports/516752

Log:
  New port: lang/ponyc-static

  A version of lang/ponyc with statically linked LLVM.

  PR:		241663

Changes:
  head/lang/Makefile
  head/lang/ponyc/Makefile
  head/lang/ponyc-static/
  head/lang/ponyc-static/Makefile