implementation of configure.env-append

Kenneth F. Cunningham ken.cunningham.webuse at gmail.com
Thu Oct 10 02:37:30 UTC 2019


On 2019-10-09, at 1:28 PM, Ryan Schmidt wrote:

>  do whatever additional work is necessary to communicate that variable to the build system, e.g. by using `build.args-append LDFLAGS="${configure.ldflags} [get_canonical_archflags ld]"` or whatever.
> 

Perhaps I'll try a new approach to this question.

Please help me understand how to have base populate the build environment variables as beautifully as base populates the configure environment variables.

eg look at this wonderful job base does of automatically setting up the configure environment:

======
--->  Configuring legacy-support
DEBUG: Preferred compilers: macports-clang-5.0 macports-clang-8.0 clang
DEBUG: Using compiler 'MacPorts Clang 5.0'
DEBUG: Executing org.macports.configure (legacy-support)
DEBUG: Environment: 
CC='/opt/local/bin/clang-mp-5.0'
CC_PRINT_OPTIONS='YES'
CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_legacy-support/legacy-support/work/.CC_PRINT_OPTIONS'
CFLAGS='-pipe -Os -arch x86_64 -arch i386'
CPATH='/opt/local/include'
CPPFLAGS='-I/opt/local/include'
CXX='/opt/local/bin/clang++-mp-5.0'
CXXFLAGS='-pipe -Os -stdlib=libc++ -arch x86_64 -arch i386'
DEVELOPER_DIR='/Applications/Xcode.app/Contents/Developer'
F90FLAGS='-pipe -Os'
FCFLAGS='-pipe -Os'
FFLAGS='-pipe -Os'
INSTALL='/usr/bin/install -c'
LDFLAGS='-L/opt/local/lib -Wl,-headerpad_max_install_names -arch x86_64 -arch i386'
LIBRARY_PATH='/opt/local/lib'
MACOSX_DEPLOYMENT_TARGET='10.7'
OBJC='/opt/local/bin/clang-mp-5.0'
OBJCFLAGS='-pipe -Os -arch x86_64 -arch i386'
OBJCXX='/opt/local/bin/clang++-mp-5.0'
OBJCXXFLAGS='-pipe -Os -stdlib=libc++ -arch x86_64 -arch i386'
======

I want all those to be in the build (and destroot) environement, and yet look at this anemic job it does on the build environment:

=======
--->  Building legacy-support
DEBUG: Executing org.macports.build (legacy-support)
DEBUG: Environment: 
CC_PRINT_OPTIONS='YES'
CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_legacy-support/legacy-support/work/.CC_PRINT_OPTIONS'
CPATH='/opt/local/include'
DEVELOPER_DIR='/Applications/Xcode.app/Contents/Developer'
LIBRARY_PATH='/opt/local/lib'
MACOSX_DEPLOYMENT_TARGET='10.7'
========



How can I have the wonderful configure environment be available in the build environment?

I have tried every incantation of 

build.env {*}${configure.env} 

etc, that I can possibly think of.


Ken


More information about the macports-dev mailing list