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

[NEW Mk/Uses/dlang.mk] Initial commit of USES=dlang support script #918

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dkgroot
Copy link
Contributor

@dkgroot dkgroot commented Nov 20, 2019

Feature: d compiler
Usage: USES=dlang
Valid args: bootstrap use bootstrap compiler when no valid d-compiler could be found

Additional variables that can be provided:
for any:

  • DLANG_USES=
    additional features enabled in dlang module
    - dub
    - rdmd
    not implemented yet (added when need arises):
    - (reggae)
    - (cmake-d / cmake)
    - (COOK)
    - (BAZEL)
    - (BUTTON)
    - (MESON)
  • DCOMPILERS
    List of d-compilers to search for through (in order)(default: ldc gdc dmd)
  • USE_LDC=yes | USE_GDC=yes | USE_DMD=yes
    Overwrite auto selection
  • DRT_MINVER
    Minimal required d-runtime version (inclusive) (default:20791)
  • DRT_MAXVER
    Maximum allowed d-runtime version (inclusive) (default:20999)
  • DLANG_DEBUG
    Print extra debug output for USES=dlang

for ldc:

  • D_REQ_LLVM LLVM version to require (60 70 80)

for gdc:

  • D_REQ_GCC GCC version to require (8 9 10)

Variables provided by dlang.mk (after bsd.ports.mk has been loaded)
for any:

  • CHOSEN_DCOMPILER_TYPE
    D compiler selected
  • DCOMPILER
    Full path to D-compiler selected.
  • DCOMPILER_DMD
    Full path to DMD interface compatible compiler selected.
  • DRUNTIME_VERSION
    D runtime version of selected D-compiler.
  • DFLAGS
    Addional DFLAGS variables to be passed to the D-compiler.
    for ldc:
  • LLVM_CONFIG
    Full path to llvm-config being used
  • LLVM_VER
    Major version of llvm being used
    for gdc:
  • GCC_VER
    Major version of gcc being used

MAINTAINER: [email protected]

Signed-off-by: ddegroot [email protected]

Feature:        d compiler
Usage:  USES=dlang
Valid args:     bootstrap       use bootstrap compiler when no valid d-compiler could be found

Additional variables that can be provided:
for any:
- DLANG_USES=
        additional features enabled in dlang module
        - dub
        - rdmd
        not implemented yet (added when need arises):
        - (reggae)
        - (cmake-d / cmake)
        - (COOK)
        - (BAZEL)
        - (BUTTON)
        - (MESON)
- DCOMPILERS
        List of d-compilers to search for through (in order)(default: ldc gdc dmd)
- USE_LDC=yes | USE_GDC=yes | USE_DMD=yes
        Overwrite auto selection
- DRT_MINVER
        Minimal required d-runtime version (inclusive) (default:20791)
- DRT_MAXVER
        Maximum allowed d-runtime version (inclusive) (default:20999)
- DLANG_DEBUG
        Print extra debug output for USES=dlang

for ldc:
- D_REQ_LLVM    LLVM version to require (60 70 80)

for gdc:
- D_REQ_GCC     GCC version to require (8 9 10)

Variables provided by dlang.mk (after bsd.ports.mk has been loaded)
for any:
- CHOSEN_DCOMPILER_TYPE
        D compiler selected
- DCOMPILER
        Full path to D-compiler selected.
- DCOMPILER_DMD
        Full path to DMD interface compatible compiler selected.
- DRUNTIME_VERSION
        D runtime version of selected D-compiler.
- DFLAGS
        Addional DFLAGS variables to be passed to the D-compiler.
for ldc:
- LLVM_CONFIG
        Full path to llvm-config being used
- LLVM_VER
        Major version of llvm being used
for gdc:
- GCC_VER
        Major version of gcc being used

MAINTAINER: [email protected]

Signed-off-by: ddegroot <[email protected]>
+OPTIONS_DEFAULT+= FORCE_BOOTSTRAP
+_INCLUDE_USES_DLANG_MK= recheck
+. else
+BUILD_DEPENDS+= ${LOCALBASE}/bin/ldc2:lang/ldc${LLVM_FLAVOR:D@${LLVM_FLAVOR}}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove the flavors as we agreed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes i will have to redesign quite a bit of it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would the other dports be excepted if these changes were made, if so i can try to make some time and finish this up. If not and freebsd ports would have to be excepted first, then it might be better to drop this and move on.

+ @${ECHO_MSG} "CPP=@${CPP}"
+.endif"
+ @${ECHO_MSG} "OPTIONS=${PORT_OPTIONS:M*}"
+ @${ECHO_MSG} "FLAVOR=${FLAVOR}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here

Copy link
Member

@tuxillo tuxillo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check my comments

@tuxillo
Copy link
Member

tuxillo commented Oct 20, 2022

What do we do with this one?

@tuxillo tuxillo marked this pull request as draft July 28, 2023 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants