root/trunk/freewrt/tools/mirmake/Makefile

Revision 3906, 1.4 kB (checked in by tg, 2 years ago)

prompted by MirBSD cid 1004B1182F9705E22AF
(in short, I didn’t read my own commentary on the API
and did an inverse logic error)

  • Property svn:keywords set to FreeWRT=Id
Line 
1 # $FreeWRT$
2 #-
3 # This file is part of the FreeWRT project. FreeWRT is copyrighted
4 # material, please see the LICENCE file in the top-level directory
5 # or at http://www.freewrt.org/licence for details.
6
7 PKG_NAME=               mirmake
8 PKG_VERSION=            20091128
9 PKG_RELEASE=            1
10 PKG_MD5SUM=             b07ee25a25e0dcd5e90e016e7e6f2b0f
11 DISTFILES=              ${PKG_NAME}-${PKG_VERSION}.cpio.gz
12 MASTER_SITES=           ${MASTER_SITE_MIRBSD:distfiles/=dist/mir/make/}
13 WRKDIST=                ${WRKDIR}/${PKG_NAME}
14
15 include ${TOPDIR}/rules.mk
16 include ../rules.mk
17
18 MIRMAKE_TOOLS=          binstall bmake lndir lorder mkdep tsort
19
20 ${WRKBUILD}/.configured: ${WRKBUILD}/.prepared
21         touch $@
22
23 ${WRKBUILD}/Install.sh: ${WRKBUILD}/.configured
24         cd ${WRKBUILD} && \
25             env CC='${HOSTCC}' CFLAGS='${HOSTCFLAGS}' NOFAKE=yes \
26             MKSH=$$(which mksh) CPPFLAGS='${HOSTCPPFLAGS} -I.' MAKEFLAGS= \
27             ${BASH} Build.sh ${OStype} ${STAGING_TOOLS} '' '' '' '' '' '' -
28
29 source: fetch
30 prepare: ${WRKBUILD}/.prepared
31
32 compile: ${WRKBUILD}/Install.sh
33
34 install: ${STAGING_TOOLS}/bin/bmake ${TOPDIR}/lbin/bmake
35
36 ${STAGING_TOOLS}/bin/bmake:
37         cd ${WRKBUILD} && ./Install.sh
38         ${MAKE} install-lbin
39
40 ${TOPDIR}/lbin/bmake: install-lbin
41
42 install-lbin:
43         for what in ${MIRMAKE_TOOLS}; do \
44                 rm -f ${TOPDIR}/lbin/$$what; \
45                 if [ -e ${STAGING_TOOLS}/bin/$$what ]; then \
46                         cp ${STAGING_TOOLS}/bin/$$what ${TOPDIR}/lbin/; \
47                 fi; \
48         done
49
50 clean:
51         rm -rf ${WRKBUILD}
52         cd ${STAGING_TOOLS}/bin; rm -f ${MIRMAKE_TOOLS}
Note: See TracBrowser for help on using the browser.