Magellan Linux

Diff of /branches/R11-unstable/include/multilib.sminc

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 20903 by niro, Thu Feb 13 14:41:09 2014 UTC revision 20977 by niro, Wed Feb 19 11:32:53 2014 UTC
# Line 294  cmake_configure() Line 294  cmake_configure()
294   local saved_SRCDIR="${SRCDIR}"   local saved_SRCDIR="${SRCDIR}"
295   for abi in ${abis_to_run}   for abi in ${abis_to_run}
296   do   do
297     cd ${BUILDDIR}/build-${abi}
298   SRCDIR="${saved_SRCDIR}-${abi}"   SRCDIR="${saved_SRCDIR}-${abi}"
  cd ${SRCDIR}/${SRCSUBDIR}  
299   abi-${abi} oldcmake_configure $@ || die   abi-${abi} oldcmake_configure $@ || die
300   done   done
301   # restore SRCDIR   # restore SRCDIR
302   SRCDIR="${saved_SRCDIR}"   SRCDIR="${saved_SRCDIR}"
303  }  }
304    
305    if [[ ! -z $(typeset -f cmake_src_compile) ]]
306    then
307     # rename the old one
308     old_cmake_src_compile=old$(typeset -f cmake_src_compile)
309     eval "${old_cmake_src_compile}"
310    fi
311    cmake_src_compile()
312    {
313     local abi
314     local abis_to_run="${MULTILIB_ABIS}"
315    
316     # respect MULTILIB_ONLY_ABI variable
317     [[ ! -z ${MULTILIB_ONLY_ABI} ]] && abis_to_run="${MULTILIB_ONLY_ABI}"
318    
319     for abi in ${abis_to_run}
320     do
321     # remove build dir if exist
322     [[ -d ${BUILDDIR}/build-${abi} ]] && rm -rf ${BUILDDIR}/build-${abi}
323    
324     # build outside of the source dir
325     install -d ${BUILDDIR}/build-${abi} || die
326     cd ${BUILDDIR}/build-${abi}
327     done
328    
329     cmake_configure || die
330    
331     for abi in ${abis_to_run}
332     do
333     cd ${BUILDDIR}/build-${abi}
334     abi-${abi} oldmmake $@ || die
335     done
336    }
337    
338    if [[ ! -z $(typeset -f cmake_src_install) ]]
339    then
340     # rename the old one
341     old_cmake_src_install=old$(typeset -f cmake_src_install)
342     eval "${old_cmake_install}"
343    fi
344    cmake_src_install()
345    {
346     local abi
347     local abis_to_run="${MULTILIB_ABIS}"
348    
349     # respect MULTILIB_ONLY_ABI variable
350     [[ ! -z ${MULTILIB_ONLY_ABI} ]] && abis_to_run="${MULTILIB_ONLY_ABI}"
351    
352     for abi in ${abis_to_run}
353     do
354     # install build outside of the source dir
355     cd ${BUILDDIR}/build-${abi}
356     abi-${abi} oldmmake DESTDIR=${BINDIR} $@ install || die
357     done
358    }
359    
360  if [[ ! -z $(typeset -f munpack) ]]  if [[ ! -z $(typeset -f munpack) ]]
361  then  then
362   # rename the old one   # rename the old one
# Line 483  multilib_src_prepare() Line 538  multilib_src_prepare()
538    
539  multilib_src_compile()  multilib_src_compile()
540  {  {
541   mconfigure || die   if [[ ! -z $(typeset -f cmake_src_compile) ]]
542   mmake || die   then
543     cmake_src_compile || die
544     else
545     mconfigure || die
546     mmake || die
547     fi
548  }  }
549    
550  multilib_src_check()  multilib_src_check()
551  {  {
552   mmake -j1 -k check || die   if [[ ! -z $(typeset -f cmake_src_check) ]]
553     then
554     cmake_src_check || die
555     else
556     mmake -j1 -k check || die
557     fi
558  }  }
559    
560  multilib_src_install()  multilib_src_install()
561  {  {
562   mmake DESTDIR=${BINDIR} install || die   if [[ ! -z $(typeset -f cmake_src_install) ]]
563     then
564     cmake_src_compile || die
565     else
566     mmake DESTDIR=${BINDIR} install || die
567     fi
568    
569   local i   local i
570   for abi in ${MULTILIB_ABIS}   for abi in ${MULTILIB_ABIS}

Legend:
Removed from v.20903  
changed lines
  Added in v.20977