Fixup fromcvs/togit conversion
[minix-pkgsrc.git] / emulators / suse121_linux / Makefile.common
blob723ecf20c64d5d4c0eadd4647a1b2ed73f037295
1 # $NetBSD: Makefile.common,v 1.2 2012/04/13 14:19:17 obache Exp $
2 # used by emulators/suse113_base/Makefile
4 SUSE_PKG=               yes
5 SUSE_VERSION=           12.1
6 EMUL_REQD=              suse>=${SUSE_VERSION}
8 # The SuSE 12.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.
10 # The non-SUSE_COMPAT32 packages are available on both i386 and x86_64
11 # and they emulate the corresponding linux platform.
12 .if !defined(SUSE_COMPAT32)
13 EMUL_PLATFORMS+=        linux-x86_64
14 ONLY_FOR_PLATFORM+=     NetBSD-5.99*-i386
15 ONLY_FOR_PLATFORM+=     NetBSD-[6-9]*-i386
16 .endif
17 EMUL_PLATFORMS+=        linux-i386
18 ONLY_FOR_PLATFORM+=     NetBSD-5.99*-x86_64
19 ONLY_FOR_PLATFORM+=     NetBSD-[6-9]*-x86_64
21 .include "../../mk/bsd.prefs.mk"
23 # _SUSE_ARCH.* is a table of ${EMUL_ARCH} to SuSE architectures.
24 _SUSE_ARCH.${EMUL_ARCH}=        ${EMUL_ARCH}
25 _SUSE_ARCH.i386=                i586
26 _SUSE_ARCH=                     ${_SUSE_ARCH.${EMUL_ARCH}}
27 SUSE_ARCH=                      ${_SUSE_ARCH}
29 _SUSE_FTP_SUBDIR=       distribution/${SUSE_VERSION}/repo/oss/suse/
30 _SUSE_FTP_SUBDIR_UPD=   update/${SUSE_VERSION}/
32 MASTER_SITE_SUSE_${SUSE_VERSION}= \
33         http://download.opensuse.org/${_SUSE_FTP_SUBDIR}
35 MASTER_SITE_SUSE_${SUSE_VERSION}_UPD= \
36         http://download.opensuse.org/${_SUSE_FTP_SUBDIR_UPD}
38 MASTER_SITES?=          ${MASTER_SITE_SUSE_${SUSE_VERSION}}/${SUSE_ARCH}/
39 DIST_SUBDIR?=           suse${SUSE_VERSION:S/.//}
41 HOMEPAGE?=              http://www.opensuse.org/
43 WRKSRC?=                ${WRKDIR}
44 BUILD_DIRS?=            # empty
45 MANCOMPRESSED?=         yes
47 EMUL_PKG_FMT?=          rpm
48 RPM2PKG_PREFIX?=        ${DESTDIR}${PREFIX}
49 RPM2PKG_SUBPREFIX?=     ${EMULSUBDIR}
50 RPM2PKG_STAGE?=         do-install
52 SUSE_PKGSRCDIR=         ${.CURDIR}/../${.CURDIR:T:S/_32_/_/}
53 FILESDIR=               ${SUSE_PKGSRCDIR}/files
54 PATCHDIR=               ${SUSE_PKGSRCDIR}/patches
55 PKGDIR=                 ${SUSE_PKGSRCDIR}
57 .if defined(SUSE_COMPAT32)
58 PKGNAME:=               ${DISTNAME:S/^suse_/suse32_/}
59 COMMENT:=               ${COMMENT:S/Linux/Linux 32-bit/}
60 .if defined(CONFLICTS)
61 CONFLICTS:=             ${CONFLICTS:S/^suse_/suse32_/}
62 .endif
63 LINUX_BASE=             linux32
64 .else
65 LINUX_BASE=             linux
66 .endif
67 PLIST_SUBST+=           LINUX_BASE=${LINUX_BASE:Q}
68 FILES_SUBST+=           LINUX_BASE=${LINUX_BASE:Q}
70 LINUX_LIBSUBDIR?=       lib
71 PLIST_SUBST+=           LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q}
72 FILES_SUBST+=           LINUX_LIBSUBDIR=${LINUX_LIBSUBDIR:Q}
74 # Include an "override" SuSE-specific and architecture-specific
75 # Makefile fragment if it exists.
77 .sinclude "${SUSE_PKGSRCDIR}/suse.${EMUL_ARCH}.mk"
79 .if defined(RPMPKGS) && !empty(RPMPKGS)
80 .  for distfile in ${RPMPKGS}
81 DISTFILES+=     ${distfile}.rpm
82 SITES.${distfile:T:S/=/--/}.rpm?=       \
83         ${MASTER_SITE_SUSE_${SUSE_VERSION}}${distfile:E}/
84 .  endfor
85 .endif
86 .if defined(RPMUPDPKGS) && !empty(RPMUPDPKGS)
87 .  for distfile in ${RPMUPDPKGS}
88 DISTFILES+=     ${distfile}.rpm
89 SITES.${distfile:T:S/=/--/}.rpm?=       \
90         ${MASTER_SITE_SUSE_${SUSE_VERSION}_UPD}${distfile:E}/
91 .  endfor
92 .endif