[BACK]Return to builtin.mk CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / graphics / MesaLib

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /pkgsrc/graphics/MesaLib/builtin.mk between version 1.4 and 1.5

version 1.4, 2004/03/29 05:43:30 version 1.5, 2005/06/01 18:02:54
Line 1 
Line 1 
 # $NetBSD$  # $NetBSD$
   
 _GL_GLX_H=      ${X11BASE}/include/GL/glx.h  BUILTIN_PKG:=   MesaLib
 _X11_TMPL=      ${X11BASE}/lib/X11/config/X11.tmpl  
   
 .include "../../graphics/Mesa/version.mk"  BUILTIN_FIND_FILES_VAR:=        H_MESALIB
 BUILDLINK_DEPENDS.MesaLib+=     MesaLib>=${_MESA_REQD}  BUILTIN_FIND_FILES.H_MESALIB=   ${X11BASE}/include/GL/glx.h
   
   .include "../../mk/buildlink3/bsd.builtin.mk"
   
   ###
   ### Determine if there is a built-in implementation of the package and
   ### set IS_BUILTIN.<pkg> appropriately ("yes" or "no").
   ###
 .if !defined(IS_BUILTIN.MesaLib)  .if !defined(IS_BUILTIN.MesaLib)
 IS_BUILTIN.MesaLib=     no  IS_BUILTIN.MesaLib=     no
 .  if exists(${_GL_GLX_H}) && exists(${_X11_TMPL})  .  if exists(${H_MESALIB})
   PKGSRC_USE_TOOLS+=      imake                   # XXX
   IMAKE?=                 ${X11BASE}/bin/imake    # XXX
   .    if defined(IMAKE) && exists(${IMAKE})
 IS_BUILTIN.MesaLib!=                                                    \  IS_BUILTIN.MesaLib!=                                                    \
         if ${GREP} -q BuildGLXLibrary ${_X11_TMPL}; then                \          ${IMAKE} -DUseInstalled -I${X11BASE}/lib/X11/config             \
                 ${ECHO} "yes";                                          \                  -f ${BUILDLINK_PKGSRCDIR.MesaLib}/builtin-imake.mk      \
         else                                                            \                  -s - |                                                  \
                 ${ECHO} "no";                                           \          ${MAKE} -f - builtin-test
         fi  
 .    if !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS])  
 #  
 # _MESA_VERSION is defined by Mesa/version.mk to be the version of the  
 # Mesa software distributed with the built-in XFree86.  
 #  
 BUILTIN_PKG.MesaLib=    MesaLib-${_MESA_VERSION}  
 BUILDLINK_VARS+=        BUILTIN_PKG.MesaLib  
 .    endif  .    endif
 .  endif  .  endif
 BUILDLINK_VARS+=        IS_BUILTIN.MesaLib  .endif
 .endif  # IS_BUILTIN.MesaLib  MAKEVARS+=      IS_BUILTIN.MesaLib
   
 .if !defined(USE_BUILTIN.MesaLib)  ###
 USE_BUILTIN.MesaLib?=   ${IS_BUILTIN.MesaLib}  ### If there is a built-in implementation, then set BUILTIN_PKG.<pkg> to
   ### a package name to represent the built-in package.
   ###
   .if !defined(BUILTIN_PKG.MesaLib) && \
       !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS]) && \
       exists(${H_MESALIB})
   .  include "../../graphics/Mesa/version.mk"
   BUILTIN_PKG.MesaLib=    MesaLib-${BUILTIN_VERSION.Mesa}
   .endif
   MAKEVARS+=      BUILTIN_PKG.MesaLib
   
 .  if defined(BUILTIN_PKG.MesaLib)  ###
 USE_BUILTIN.MesaLib=            yes  ### Determine whether we should use the built-in implementation if it
 .    for _depend_ in ${BUILDLINK_DEPENDS.MesaLib}  ### exists, and set USE_BUILTIN.<pkg> appropriate ("yes" or "no").
 .      if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])  ###
 USE_BUILTIN.MesaLib!=   \  .if !defined(USE_BUILTIN.MesaLib)
         if ${PKG_ADMIN} pmatch '${_depend_}' ${BUILTIN_PKG.MesaLib}; then \  .  if ${PREFER.MesaLib} == "pkgsrc"
                 ${ECHO} "yes";                                          \  USE_BUILTIN.MesaLib=    no
   .  else
   USE_BUILTIN.MesaLib=    ${IS_BUILTIN.MesaLib}
   .    if defined(BUILTIN_PKG.MesaLib) && \
           !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS])
   USE_BUILTIN.MesaLib=    yes
   .      for _dep_ in ${BUILDLINK_DEPENDS.MesaLib}
   .        if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])
   USE_BUILTIN.MesaLib!=                                                   \
           if ${PKG_ADMIN} pmatch ${_dep_:Q} ${BUILTIN_PKG.MesaLib:Q}; then \
                   ${ECHO} yes;                                            \
         else                                                            \          else                                                            \
                 ${ECHO} "no";                                           \                  ${ECHO} no;                                             \
         fi          fi
 .      endif  .        endif
 .    endfor  .      endfor
 .  endif  .    endif
 .endif  # USE_BUILTIN.MesaLib  .  endif  # PREFER.MesaLib
   .endif
   MAKEVARS+=      USE_BUILTIN.MesaLib
   
   ###
   ### The section below only applies if we are not including this file
   ### solely to determine whether a built-in implementation exists.
   ###
 CHECK_BUILTIN.MesaLib?= no  CHECK_BUILTIN.MesaLib?= no
 .if !empty(CHECK_BUILTIN.MesaLib:M[nN][oO])  .if !empty(CHECK_BUILTIN.MesaLib:M[nN][oO])
   
 .if !empty(USE_BUILTIN.MesaLib:M[nN][oO])  .  if !empty(USE_BUILTIN.MesaLib:M[nN][oO])
 BUILDLINK_DEPENDS.MesaLib+=     MesaLib>=6.0  BUILDLINK_DEPENDS.MesaLib+=     MesaLib>=6.0
 .endif  .  endif
   
 .if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])  .  if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])
 BUILDLINK_PREFIX.MesaLib=       ${X11BASE}  BUILDLINK_PREFIX.MesaLib=       ${X11BASE}
 USE_X11=                        yes  BUILDLINK_DEPTH:=               ${BUILDLINK_DEPTH}+
 _MESA_REQD=                     ${_MESA_VERSION}  .    include "../../mk/x11.buildlink3.mk"
 .endif  .    include "../../mk/x11.builtin.mk"
   BUILDLINK_DEPTH:=               ${BUILDLINK_DEPTH:S/+$//}
   .  endif
   
 .endif  # CHECK_BUILTIN.MesaLib  .endif  # CHECK_BUILTIN.MesaLib

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

CVSweb <webmaster@jp.NetBSD.org>