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

Annotation of pkgsrc/graphics/MesaLib/builtin.mk, Revision 1.13

1.13    ! jlam        1: # $NetBSD: builtin.mk,v 1.12 2006/01/19 12:53:17 adam Exp $
1.1       jlam        2:
1.5       jlam        3: BUILTIN_PKG:=  MesaLib
1.1       jlam        4:
1.5       jlam        5: BUILTIN_FIND_FILES_VAR:=       H_MESALIB
                      6: BUILTIN_FIND_FILES.H_MESALIB=  ${X11BASE}/include/GL/glx.h
1.1       jlam        7:
1.5       jlam        8: .include "../../mk/buildlink3/bsd.builtin.mk"
                      9:
                     10: ###
                     11: ### Determine if there is a built-in implementation of the package and
                     12: ### set IS_BUILTIN.<pkg> appropriately ("yes" or "no").
                     13: ###
1.1       jlam       14: .if !defined(IS_BUILTIN.MesaLib)
                     15: IS_BUILTIN.MesaLib=    no
1.13    ! jlam       16: .  if empty(H_MESALIB:M__nonexistent__)
1.9       jlam       17: BUILTIN_IMAKE_CHECK:=  MesaLib:BuildGLXLibrary
                     18: .    include "../../mk/buildlink3/imake-check.mk"
                     19: IS_BUILTIN.MesaLib=    ${BUILTIN_IMAKE_CHECK.MesaLib}
1.1       jlam       20: .  endif
1.5       jlam       21: .endif
                     22: MAKEVARS+=     IS_BUILTIN.MesaLib
1.1       jlam       23:
1.5       jlam       24: ###
                     25: ### If there is a built-in implementation, then set BUILTIN_PKG.<pkg> to
                     26: ### a package name to represent the built-in package.
                     27: ###
                     28: .if !defined(BUILTIN_PKG.MesaLib) && \
                     29:     !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS]) && \
1.13    ! jlam       30:     empty(H_MESALIB:M__nonexistent__)
1.5       jlam       31: .  include "../../graphics/Mesa/version.mk"
                     32: BUILTIN_PKG.MesaLib=   MesaLib-${BUILTIN_VERSION.Mesa}
                     33: .endif
                     34: MAKEVARS+=     BUILTIN_PKG.MesaLib
                     35:
                     36: ###
                     37: ### Determine whether we should use the built-in implementation if it
                     38: ### exists, and set USE_BUILTIN.<pkg> appropriate ("yes" or "no").
                     39: ###
1.1       jlam       40: .if !defined(USE_BUILTIN.MesaLib)
1.5       jlam       41: .  if ${PREFER.MesaLib} == "pkgsrc"
                     42: USE_BUILTIN.MesaLib=   no
                     43: .  else
                     44: USE_BUILTIN.MesaLib=   ${IS_BUILTIN.MesaLib}
                     45: .    if defined(BUILTIN_PKG.MesaLib) && \
                     46:         !empty(IS_BUILTIN.MesaLib:M[yY][eE][sS])
                     47: USE_BUILTIN.MesaLib=   yes
1.12      adam       48: .      for dep in ${BUILDLINK_DEPENDS.MesaLib}
1.5       jlam       49: .        if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])
                     50: USE_BUILTIN.MesaLib!=                                                  \
1.12      adam       51:        if ${PKG_ADMIN} pmatch ${dep:Q} ${BUILTIN_PKG.MesaLib:Q}; then \
1.5       jlam       52:                ${ECHO} yes;                                            \
1.1       jlam       53:        else                                                            \
1.5       jlam       54:                ${ECHO} no;                                             \
1.1       jlam       55:        fi
1.5       jlam       56: .        endif
                     57: .      endfor
                     58: .    endif
                     59: .  endif  # PREFER.MesaLib
                     60: .endif
                     61: MAKEVARS+=     USE_BUILTIN.MesaLib
1.1       jlam       62:
1.5       jlam       63: ###
                     64: ### The section below only applies if we are not including this file
                     65: ### solely to determine whether a built-in implementation exists.
                     66: ###
1.4       jlam       67: CHECK_BUILTIN.MesaLib?=        no
                     68: .if !empty(CHECK_BUILTIN.MesaLib:M[nN][oO])
                     69:
1.5       jlam       70: .  if !empty(USE_BUILTIN.MesaLib:M[nN][oO])
1.10      jlam       71: BUILDLINK_DEPTH:=              ${BUILDLINK_DEPTH}+
                     72: .    include "../../mk/pthread.buildlink3.mk"
                     73: .    include "../../mk/pthread.builtin.mk"
                     74: BUILDLINK_DEPTH:=              ${BUILDLINK_DEPTH:S/+$//}
1.5       jlam       75: .  endif
1.1       jlam       76:
1.5       jlam       77: .  if !empty(USE_BUILTIN.MesaLib:M[yY][eE][sS])
1.1       jlam       78: BUILDLINK_PREFIX.MesaLib=      ${X11BASE}
1.5       jlam       79: BUILDLINK_DEPTH:=              ${BUILDLINK_DEPTH}+
                     80: .    include "../../mk/x11.buildlink3.mk"
                     81: .    include "../../mk/x11.builtin.mk"
                     82: BUILDLINK_DEPTH:=              ${BUILDLINK_DEPTH:S/+$//}
                     83: .  endif
1.4       jlam       84:
                     85: .endif # CHECK_BUILTIN.MesaLib

CVSweb <webmaster@jp.NetBSD.org>