Makefile 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(TOPDIR)/rules.mk
  4. PKG_NAME:= MesaLib
  5. PKG_VERSION:= 7.8.2
  6. PKG_RELEASE:= 2
  7. PKG_MD5SUM:= c89b63d253605ed40e8ac370d25a833c
  8. PKG_DESCR:= MESA library
  9. PKG_SECTION:= libs
  10. PKG_DEPENDS:= libxdamage libxfixes libdrm libxxf86vm
  11. PKG_BUILDDEP:= libXdamage libXfixes libXxf86vm libdrm
  12. PKG_BUILDDEP+= dri2proto glproto expat
  13. PKG_URL:= http://www.mesa3d.org/
  14. PKG_SITES:= ftp://ftp.freedesktop.org/pub/mesa/7.8.2/
  15. PKG_SUBPKGS:= MESALIB GLXINFO GLXGEARS
  16. PKGSD_GLXINFO:= Display various GLX information
  17. PKGSC_GLXINFO:= x11/apps
  18. PKGSD_GLXGEARS:= Nice little OpenGL demo application
  19. PKGSC_GLXGEARS:= x11/apps
  20. PKG_HOST_DEPENDS:= !cygwin !darwin
  21. PKG_TARGET_DEPENDS:= x86 x86_64 mips mipsel mips64 mips64el
  22. WRKDIST= ${WRKDIR}/Mesa-${PKG_VERSION}
  23. include $(TOPDIR)/mk/package.mk
  24. $(eval $(call PKG_template,MESALIB,mesalib,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  25. $(eval $(call PKG_template,GLXINFO,glxinfo,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_GLXINFO},${PKGSC_GLXINFO}))
  26. $(eval $(call PKG_template,GLXGEARS,glxgears,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_GLXGEARS},${PKGSC_GLXGEARS}))
  27. ifeq (${ADK_HARDWARE_IBM_X40},y)
  28. DRI_DRIVERS:=i915
  29. endif
  30. CONFIGURE_ARGS+= --disable-static \
  31. --disable-gallium \
  32. --disable-glw \
  33. --with-driver=dri \
  34. --with-dri-drivers=${DRI_DRIVERS},swrast \
  35. --with-demos=xdemos
  36. XAKE_FLAGS+= HOST_CC=${HOSTCC}
  37. pre-configure:
  38. (cd ${WRKBUILD}; rm -rf config.{cache,status}; \
  39. ./configure \
  40. --disable-static \
  41. --disable-glw \
  42. --disable-gallium \
  43. --with-driver=xlib \
  44. );
  45. ${MAKE} -C ${WRKBUILD}/src/glsl
  46. ${MAKE} -C ${WRKBUILD}/src/glsl/apps
  47. ${CP} ${WRKBUILD}/src/glsl/apps/compile \
  48. ${STAGING_TOOLS}/bin
  49. ${MAKE} -C ${WRKBUILD}/src/glsl clean
  50. post-install:
  51. $(INSTALL_DIR) $(IDIR_MESALIB)/usr/lib/dri
  52. $(CP) $(WRKINST)/usr/lib/libGL*.so* \
  53. $(IDIR_MESALIB)/usr/lib
  54. ifeq (${ADK_HARDWARE_IBM_X40},y)
  55. ${CP} $(WRKINST)/usr/lib/dri/i915_dri.so \
  56. ${IDIR_MESALIB}/usr/lib/dri/
  57. endif
  58. ${CP} $(WRKINST)/usr/lib/dri/swrast_dri.so \
  59. ${IDIR_MESALIB}/usr/lib/dri/
  60. ${INSTALL_DIR} ${IDIR_GLXINFO}/usr/bin
  61. ${INSTALL_BIN} ${WRKBUILD}/progs/xdemos/glxinfo \
  62. ${IDIR_GLXINFO}/usr/bin/
  63. ${INSTALL_DIR} ${IDIR_GLXGEARS}/usr/bin
  64. ${INSTALL_BIN} ${WRKBUILD}/progs/xdemos/glxgears \
  65. ${IDIR_GLXGEARS}/usr/bin/
  66. include ${TOPDIR}/mk/pkg-bottom.mk