Ticket #52742: variants-mpbb-fully-outdated.diff

File variants-mpbb-fully-outdated.diff, 2.6 KB (added by mojca (Mojca Miklavec), 8 years ago)

outdated patch for basic support of variants in mpbb

  • mpbb

     
    88option_default_archive_site=https://packages.macports.org
    99option_default_help=0
    1010option_default_port=
     11option_default_variants=
    1112option_default_prefix=/opt/local
    1213option_default_staging_dir=${PWD:-/tmp/mp-buildbot}/archive-staging
    1314option_default_svn=$(which svn)
     
    1819option_archive_site=$option_default_archive_site
    1920option_help=$option_default_help
    2021option_port=$option_default_port
     22option_variants=$option_default_variants
    2123option_prefix=$option_default_prefix
    2224option_staging_dir=$option_default_staging_dir
    2325option_svn=$option_default_svn
     
    135137                    option_port=$2
    136138                    shift
    137139                    ;;
     140                --variants)
     141                    option_variants=$2
     142                    shift
     143                    ;;
    138144                --prefix)
    139145                    option_prefix=$2
    140146                    shift
  • mpbb-install-dependencies

     
    2626    > "$log_status_dependencies"
    2727
    2828    # calculate list of dependencies in-order
    29     dependencies=$("${option_prefix}/bin/port-tclsh" "${thisdir}/tools/dependencies.tcl" "${option_port}")
     29    dependencies=$("${option_prefix}/bin/port-tclsh" "${thisdir}/tools/dependencies.tcl" "${option_port}" ${option_variants})
    3030    if [ $? -ne 0 ]; then
    3131        echo "Calculating dependencies for '${option_port}' failed, aborting." >&2
    3232        echo "[FAIL dependencies]" >> "$log_subports_progress"
     
    6060        text="Installing dependency ($dependencies_counter of $dependencies_count) '${depname}' with variants '${depvariants}'"
    6161        echo "----> ${text}"
    6262        echo -n "${text} ... " >> "$log_status_dependencies"
    63         if ! "${option_prefix}/bin/port" -d install --unrequested "$depname" $depvariants; then
     63        if ! "${option_prefix}/bin/port" -d install --unrequested "$depname" $depvariants ${option_variants}; then
    6464            echo "Build of dependency '${depname}' failed, aborting." >&2
    6565            echo "[FAIL]" >> "$log_status_dependencies"
    6666            echo "[FAIL dependency '${depname}']" >> "$log_subports_progress"
  • mpbb-install-port

     
    2929    echo -n "- Installing ${option_port} ... " >> "$log_subports_progress"
    3030
    3131    local time_start=$(date +%s)
    32     if ! "${option_prefix}/bin/port" -dk install "${option_port}"; then
     32    if ! "${option_prefix}/bin/port" -dk install "${option_port}" ${option_variants}; then
    3333        echo "Build of '${option_port}' failed."
    3434        echo "[FAIL]" >> "$log_subports_progress"
    3535        return 1