diff --git a/xbps-src/shutils/build_funcs.sh b/xbps-src/shutils/build_funcs.sh index 08b47d156f..5d7d94c32a 100644 --- a/xbps-src/shutils/build_funcs.sh +++ b/xbps-src/shutils/build_funcs.sh @@ -35,26 +35,29 @@ build_src_phase() # # Skip this phase for: meta-template, only-install, custom-install - # and python-module style builds. + # style builds. # [ "$build_style" = "meta-template" -o \ "$build_style" = "only-install" -o \ - "$build_style" = "custom-install" -o \ - "$build_style" = "python-module" ] && return 0 + "$build_style" = "custom-install" ] && return 0 [ ! -d $wrksrc ] && msg_error "unexistent build directory [$wrksrc]" cd $wrksrc || exit 1 [ -n "$revision" ] && pkg="${pkg}_${revision}" - [ -z "$make_cmd" ] && make_cmd=/usr/bin/make + if [ "$build_style" = "python-module" ]; then + make_cmd="python" + make_build_args="setup.py build" + else + [ -z "$make_cmd" ] && make_cmd=/usr/bin/make + [ -n "$XBPS_MAKEJOBS" -a -z "$disable_parallel_build" ] && \ + makejobs="-j$XBPS_MAKEJOBS" + fi # Run pre_build func. run_func pre_build || msg_error "pre_build stage failed!" - [ -n "$XBPS_MAKEJOBS" -a -z "$disable_parallel_build" ] && \ - makejobs="-j$XBPS_MAKEJOBS" - . $XBPS_SHUTILSDIR/buildvars_funcs.sh set_build_vars diff --git a/xbps-src/shutils/configure_funcs.sh b/xbps-src/shutils/configure_funcs.sh index 1949389636..1d74c3e0a1 100644 --- a/xbps-src/shutils/configure_funcs.sh +++ b/xbps-src/shutils/configure_funcs.sh @@ -41,13 +41,12 @@ configure_src_phase() # # Skip this phase for: meta-template, only-install, custom-install, - # gnu_makefile and python-module style builds. + # gnu_makefile style builds. # [ "$build_style" = "meta-template" -o \ "$build_style" = "only-install" -o \ "$build_style" = "custom-install" -o \ - "$build_style" = "gnu_makefile" -o \ - "$build_style" = "python-module" ] && return 0 + "$build_style" = "gnu_makefile" ] && return 0 if [ -n "$revision" ]; then lver="${version}_${revision}" @@ -97,6 +96,13 @@ configure_src_phase() . $XBPS_HELPERSDIR/perl-module.sh perl_module_build $pkgname ;; + python-module) + # + # Packages that are python modules and use setup.py files. + # They are all handled by the helper python-module.sh. + # + python setup.py configure ${configure_args} + ;; *) # # Unknown build_style type won't work :-)