| @@ -1,92 +1,129 @@ | | | @@ -1,92 +1,129 @@ |
1 | # $NetBSD: Makefile.common,v 1.1 2013/12/05 11:42:16 obache Exp $ | | 1 | # $NetBSD: Makefile.common,v 1.2 2014/01/23 11:10:17 obache Exp $ |
| | | 2 | # used by emulators/suse131_alsa/Makefile |
| | | 3 | # used by emulators/suse131_aspell/Makefile |
2 | # used by emulators/suse131_base/Makefile | | 4 | # used by emulators/suse131_base/Makefile |
| | | 5 | # used by emulators/suse131_compat/Makefile |
| | | 6 | # used by emulators/suse131_cyrus-sasl/Makefile |
| | | 7 | # used by emulators/suse131_dbus-glib/Makefile |
| | | 8 | # used by emulators/suse131_expat/Makefile |
| | | 9 | # used by emulators/suse131_fontconfig/Makefile |
| | | 10 | # used by emulators/suse131_freetype2/Makefile |
| | | 11 | # used by emulators/suse131_glib2/Makefile |
| | | 12 | # used by emulators/suse131_glx/Makefile |
| | | 13 | # used by emulators/suse131_gtk2/Makefile |
| | | 14 | # used by emulators/suse131_krb5/Makefile |
| | | 15 | # used by emulators/suse131_libcups/Makefile |
| | | 16 | # used by emulators/suse131_libcurl/Makefile |
| | | 17 | # used by emulators/suse131_libdbus/Makefile |
| | | 18 | # used by emulators/suse131_libdrm/Makefile |
| | | 19 | # used by emulators/suse131_libffi/Makefile |
| | | 20 | # used by emulators/suse131_libidn/Makefile |
| | | 21 | # used by emulators/suse131_libjpeg/Makefile |
| | | 22 | # used by emulators/suse131_libjson/Makefile |
| | | 23 | # used by emulators/suse131_libpng/Makefile |
| | | 24 | # used by emulators/suse131_libsigc++2/Makefile |
| | | 25 | # used by emulators/suse131_libsndfile/Makefile |
| | | 26 | # used by emulators/suse131_libssh/Makefile |
| | | 27 | # used by emulators/suse131_libtiff/Makefile |
| | | 28 | # used by emulators/suse131_libwrap/Makefile |
| | | 29 | # used by emulators/suse131_libxml2/Makefile |
| | | 30 | # used by emulators/suse131_locale/Makefile |
| | | 31 | # used by emulators/suse131_motif/Makefile |
| | | 32 | # used by emulators/suse131_mozilla-nspr/Makefile |
| | | 33 | # used by emulators/suse131_mozilla-nss/Makefile |
| | | 34 | # used by emulators/suse131_openldap/Makefile |
| | | 35 | # used by emulators/suse131_openssl/Makefile |
| | | 36 | # used by emulators/suse131_pulseaudio/Makefile |
| | | 37 | # used by emulators/suse131_qt4/Makefile |
| | | 38 | # used by emulators/suse131_slang/Makefile |
| | | 39 | # used by emulators/suse131_x11/Makefile |
3 | | | 40 | |
4 | SUSE_PKG= yes | | 41 | SUSE_PKG= yes |
5 | SUSE_VERSION= 13.1 | | 42 | SUSE_VERSION= 13.1 |
6 | EMUL_REQD= suse>=${SUSE_VERSION} | | 43 | EMUL_REQD= suse>=${SUSE_VERSION} |
7 | | | 44 | |
8 | # The SuSE 13.x Linux packages are only usable on the following platforms. | | 45 | # The SuSE 13.x Linux packages are only usable on the following platforms. |
9 | # The SUSE_COMPAT32 packages are available only on x86_64 and they emulate i386. | | 46 | # The SUSE_COMPAT32 packages are available only on x86_64 and they emulate i386. |
10 | # The non-SUSE_COMPAT32 packages are available on both i386 and x86_64 | | 47 | # The non-SUSE_COMPAT32 packages are available on both i386 and x86_64 |
11 | # and they emulate the corresponding linux platform. | | 48 | # and they emulate the corresponding linux platform. |
12 | .if !defined(SUSE_COMPAT32) | | 49 | .if !defined(SUSE_COMPAT32) |
13 | EMUL_PLATFORMS+= linux-x86_64 | | 50 | EMUL_PLATFORMS+= linux-x86_64 |
14 | ONLY_FOR_PLATFORM+= NetBSD-5.99*-i386 | | 51 | ONLY_FOR_PLATFORM+= NetBSD-5.99*-i386 |
15 | ONLY_FOR_PLATFORM+= NetBSD-[6-9]*-i386 | | 52 | ONLY_FOR_PLATFORM+= NetBSD-[6-9]*-i386 |
16 | .endif | | 53 | .endif |
17 | EMUL_PLATFORMS+= linux-i386 | | 54 | EMUL_PLATFORMS+= linux-i386 |
18 | ONLY_FOR_PLATFORM+= NetBSD-5.99*-x86_64 | | 55 | ONLY_FOR_PLATFORM+= NetBSD-5.99*-x86_64 |
19 | ONLY_FOR_PLATFORM+= NetBSD-[6-9]*-x86_64 | | 56 | ONLY_FOR_PLATFORM+= NetBSD-[6-9]*-x86_64 |
20 | | | 57 | |
21 | .include "../../mk/bsd.prefs.mk" | | 58 | .include "../../mk/bsd.prefs.mk" |
22 | | | 59 | |
23 | # _SUSE_ARCH.* is a table of ${EMUL_ARCH} to SuSE architectures. | | 60 | # _SUSE_ARCH.* is a table of ${EMUL_ARCH} to SuSE architectures. |
24 | _SUSE_ARCH.${EMUL_ARCH}= ${EMUL_ARCH} | | 61 | _SUSE_ARCH.${EMUL_ARCH}= ${EMUL_ARCH} |
25 | _SUSE_ARCH.i386= i586 | | 62 | _SUSE_ARCH.i386= i586 |
26 | _SUSE_ARCH= ${_SUSE_ARCH.${EMUL_ARCH}} | | 63 | _SUSE_ARCH= ${_SUSE_ARCH.${EMUL_ARCH}} |
27 | SUSE_ARCH= ${_SUSE_ARCH} | | 64 | SUSE_ARCH= ${_SUSE_ARCH} |
28 | | | 65 | |
29 | _SUSE_FTP_SUBDIR= distribution/${SUSE_VERSION}/repo/oss/suse/ | | 66 | _SUSE_FTP_SUBDIR= distribution/${SUSE_VERSION}/repo/oss/suse/ |
30 | _SUSE_FTP_SUBDIR_UPD= update/${SUSE_VERSION}/ | | 67 | _SUSE_FTP_SUBDIR_UPD= update/${SUSE_VERSION}/ |
31 | | | 68 | |
32 | MASTER_SITE_SUSE_${SUSE_VERSION}= \ | | 69 | MASTER_SITE_SUSE_${SUSE_VERSION}= \ |
33 | http://download.opensuse.org/${_SUSE_FTP_SUBDIR} | | 70 | http://download.opensuse.org/${_SUSE_FTP_SUBDIR} |
34 | | | 71 | |
35 | MASTER_SITE_SUSE_${SUSE_VERSION}_UPD= \ | | 72 | MASTER_SITE_SUSE_${SUSE_VERSION}_UPD= \ |
36 | http://download.opensuse.org/${_SUSE_FTP_SUBDIR_UPD} | | 73 | http://download.opensuse.org/${_SUSE_FTP_SUBDIR_UPD} |
37 | | | 74 | |
38 | MASTER_SITES?= ${MASTER_SITE_SUSE_${SUSE_VERSION}}/${SUSE_ARCH}/ | | 75 | MASTER_SITES?= ${MASTER_SITE_SUSE_${SUSE_VERSION}}/${SUSE_ARCH}/ |
39 | DIST_SUBDIR?= suse${SUSE_VERSION:S/.//} | | 76 | DIST_SUBDIR?= suse${SUSE_VERSION:S/.//} |
40 | | | 77 | |
41 | HOMEPAGE?= http://www.opensuse.org/ | | 78 | HOMEPAGE?= http://www.opensuse.org/ |
42 | | | 79 | |
43 | WRKSRC?= ${WRKDIR} | | 80 | WRKSRC?= ${WRKDIR} |
44 | BUILD_DIRS?= # empty | | 81 | BUILD_DIRS?= # empty |
45 | MANCOMPRESSED?= yes | | 82 | MANCOMPRESSED?= yes |
46 | | | 83 | |
47 | EMUL_PKG_FMT?= rpm | | 84 | EMUL_PKG_FMT?= rpm |
48 | RPM2PKG_PREFIX?= ${DESTDIR}${PREFIX} | | 85 | RPM2PKG_PREFIX?= ${DESTDIR}${PREFIX} |
49 | RPM2PKG_SUBPREFIX?= ${EMULSUBDIR} | | 86 | RPM2PKG_SUBPREFIX?= ${EMULSUBDIR} |
50 | RPM2PKG_STAGE?= do-install | | 87 | RPM2PKG_STAGE?= do-install |
51 | | | 88 | |
52 | SUSE_PKGSRCDIR= ${.CURDIR}/../${.CURDIR:T:S/_32_/_/} | | 89 | SUSE_PKGSRCDIR= ${.CURDIR}/../${.CURDIR:T:S/_32_/_/} |
53 | FILESDIR= ${SUSE_PKGSRCDIR}/files | | 90 | FILESDIR= ${SUSE_PKGSRCDIR}/files |
54 | PATCHDIR= ${SUSE_PKGSRCDIR}/patches | | 91 | PATCHDIR= ${SUSE_PKGSRCDIR}/patches |
55 | PKGDIR= ${SUSE_PKGSRCDIR} | | 92 | PKGDIR= ${SUSE_PKGSRCDIR} |
56 | | | 93 | |
57 | .if defined(SUSE_COMPAT32) | | 94 | .if defined(SUSE_COMPAT32) |
58 | PKGNAME:= ${DISTNAME:S/^suse_/suse32_/} | | 95 | PKGNAME:= ${DISTNAME:S/^suse_/suse32_/} |
59 | COMMENT:= ${COMMENT:S/Linux/Linux 32-bit/} | | 96 | COMMENT:= ${COMMENT:S/Linux/Linux 32-bit/} |
60 | .if defined(CONFLICTS) | | 97 | .if defined(CONFLICTS) |
61 | CONFLICTS:= ${CONFLICTS:S/^suse_/suse32_/} | | 98 | CONFLICTS:= ${CONFLICTS:S/^suse_/suse32_/} |
62 | .endif | | 99 | .endif |
63 | LINUX_BASE= linux32 | | 100 | LINUX_BASE= linux32 |
64 | .else | | 101 | .else |
65 | LINUX_BASE= linux | | 102 | LINUX_BASE= linux |
66 | .endif | | 103 | .endif |
67 | PLIST_SUBST+= LINUX_BASE=${LINUX_BASE:Q} | | 104 | PLIST_SUBST+= LINUX_BASE=${LINUX_BASE:Q} |
68 | FILES_SUBST+= LINUX_BASE=${LINUX_BASE:Q} | | 105 | FILES_SUBST+= LINUX_BASE=${LINUX_BASE:Q} |
69 | | | 106 | |
70 | LINUX_LIBSUBDIR?= lib | | 107 | LINUX_LIBSUBDIR?= lib |
71 | PLIST_SUBST+= LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q} | | 108 | PLIST_SUBST+= LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q} |
72 | FILES_SUBST+= LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q} | | 109 | FILES_SUBST+= LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q} |
73 | | | 110 | |
74 | # Include an "override" SuSE-specific and architecture-specific | | 111 | # Include an "override" SuSE-specific and architecture-specific |
75 | # Makefile fragment if it exists. | | 112 | # Makefile fragment if it exists. |
76 | # | | 113 | # |
77 | .sinclude "${SUSE_PKGSRCDIR}/suse.${EMUL_ARCH}.mk" | | 114 | .sinclude "${SUSE_PKGSRCDIR}/suse.${EMUL_ARCH}.mk" |
78 | | | 115 | |
79 | .if defined(RPMPKGS) && !empty(RPMPKGS) | | 116 | .if defined(RPMPKGS) && !empty(RPMPKGS) |
80 | . for distfile in ${RPMPKGS} | | 117 | . for distfile in ${RPMPKGS} |
81 | DISTFILES+= ${distfile}.rpm | | 118 | DISTFILES+= ${distfile}.rpm |
82 | SITES.${distfile:T:S/=/--/}.rpm?= \ | | 119 | SITES.${distfile:T:S/=/--/}.rpm?= \ |
83 | ${MASTER_SITE_SUSE_${SUSE_VERSION}}${distfile:E}/ | | 120 | ${MASTER_SITE_SUSE_${SUSE_VERSION}}${distfile:E}/ |
84 | . endfor | | 121 | . endfor |
85 | .endif | | 122 | .endif |
86 | .if defined(RPMUPDPKGS) && !empty(RPMUPDPKGS) | | 123 | .if defined(RPMUPDPKGS) && !empty(RPMUPDPKGS) |
87 | . for distfile in ${RPMUPDPKGS} | | 124 | . for distfile in ${RPMUPDPKGS} |
88 | DISTFILES+= ${distfile}.rpm | | 125 | DISTFILES+= ${distfile}.rpm |
89 | SITES.${distfile:T:S/=/--/}.rpm?= \ | | 126 | SITES.${distfile:T:S/=/--/}.rpm?= \ |
90 | ${MASTER_SITE_SUSE_${SUSE_VERSION}_UPD}${distfile:E}/ | | 127 | ${MASTER_SITE_SUSE_${SUSE_VERSION}_UPD}${distfile:E}/ |
91 | . endfor | | 128 | . endfor |
92 | .endif | | 129 | .endif |