summaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorxtraeme <xtraeme@pkgsrc.org>2007-04-19 15:31:07 +0000
committerxtraeme <xtraeme@pkgsrc.org>2007-04-19 15:31:07 +0000
commitcddedfbffc99214fb7e388700dd44031f726e965 (patch)
treec2cf0ca0945aa3b84ed26b4166e6bd62becd68b4 /emulators
parent78d4bc67e9c4dfb991c13d4a63fb27aac9be67cd (diff)
downloadpkgsrc-cddedfbffc99214fb7e388700dd44031f726e965.tar.gz
Add missing file required by suse32/64.
Diffstat (limited to 'emulators')
-rw-r--r--emulators/suse100_linux/compat32.mk78
1 files changed, 78 insertions, 0 deletions
diff --git a/emulators/suse100_linux/compat32.mk b/emulators/suse100_linux/compat32.mk
new file mode 100644
index 00000000000..c41a7953c7b
--- /dev/null
+++ b/emulators/suse100_linux/compat32.mk
@@ -0,0 +1,78 @@
+# $NetBSD: compat32.mk,v 1.1 2007/04/19 15:31:07 xtraeme Exp $
+#
+
+.ifndef SUSE_LINUX_COMPAT32_MK
+SUSE_LINUX_COMPAT32_MK= # defined
+
+. if ${OPSYS} == "NetBSD" && ${MACHINE_ARCH} == "x86_64"
+
+#
+# We must protect this part with packages that are using
+# the options framework, otherwise we'll end executing two
+# targets for the options.
+#
+. ifndef SUSE_COMPAT32_OPT
+PKG_OPTIONS_VAR= PKG_OPTIONS.suse
+PKG_SUPPORTED_OPTIONS= compat32
+
+. include "../../mk/bsd.options.mk"
+. else
+ONLY_FOR_PLATFORM:= ${ONLY_FOR_PLATFORM} NetBSD-*-x86_64
+#MACHINE_ARCH:= i386
+DEPENDS:= ${DEPENDS:S/suse/suse32/}
+EMULSUBDIR:= emul/linux32
+. endif
+
+STRING_ERROR1= \
+ "This package is not compatible with x86_64 without using "
+STRING_ERROR2= \
+ "PKG_OPTIONS.suse=compat32."
+MYSTRING= ${STRING_ERROR1}${STRING_ERROR2}
+
+. if !empty(PKG_OPTIONS:Mcompat32)
+#
+# We don't need to override the following vars in packages using
+# SUSE_COMPAT32, because this is only required for the suse
+# packages.
+#
+. ifndef SUSE_COMPAT32
+#
+# Override required vars
+#
+PKGNAME:= ${DISTNAME:S/suse/suse32/}
+COMMENT:= ${COMMENT:S/Linux/Linux 32/}
+SUSE_ARCH:= i586
+. endif
+#
+# This is common for all linux packages.
+#
+MACHINE_ARCH:= i386
+ARCH:= ${MACHINE_ARCH}
+DEPENDS:= ${DEPENDS:S/suse/suse32/}
+LINUX_LIB:= lib
+BINSUFFIX:= # empty
+#
+# Use the correct directories.
+#
+OPSYS_EMULSUBDIR= linux32
+SUSE_COMPAT32_SUFFIX= 32
+EMULSUBDIR:= emul/linux32
+. else
+OPSYS_EMULSUBDIR= linux
+SUSE_COMPAT32_SUFFIX= # empty
+. if empty(ONLY_FOR_PLATFORM:MNetBSD-*-x86_64)
+PKG_FAIL_REASON+= ${MYSTRING}
+. endif
+. endif # end of PKG_OPTIONS.suse=compat32
+#
+# This is to avoid to use the same code on every package
+# many times.
+#
+. ifdef SUSE_INCLUDE_MAKEFILE_ARCH
+. if exists(Makefile.${MACHINE_ARCH})
+. include "Makefile.${MACHINE_ARCH}"
+. endif
+. endif
+. endif # end of NetBSD && x86_64
+
+.endif # end of SUSE_LINUX_COMPAT32_MK