From 64079a44f7fce4283b875dbefbf76f2970a3b21c Mon Sep 17 00:00:00 2001 From: Cliff Brake Date: Thu, 27 Sep 2007 16:11:59 +0000 Subject: mono-1.2.5.1: add new version, and remove 1.2.5 --- packages/mono/mono_1.2.5.1.bb | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 packages/mono/mono_1.2.5.1.bb (limited to 'packages/mono/mono_1.2.5.1.bb') diff --git a/packages/mono/mono_1.2.5.1.bb b/packages/mono/mono_1.2.5.1.bb new file mode 100644 index 0000000000..c0a4cfb223 --- /dev/null +++ b/packages/mono/mono_1.2.5.1.bb @@ -0,0 +1,23 @@ +require mono_1.2.5.inc + +#DEPENDS = "mono-native glib-2.0" +# for now, we skip the mono-native build -- just install +# mono using your distro package manager for now +# after we get the target version working, we'll worry +# about the native package for systems that don't have mono +# installed +DEPENDS = "glib-2.0" + +PR = "r0" + +SRC_URI += "file://configure.patch;patch=1" + +do_install_append() { + install -d ${D}${libdir}/mono/1.0/ + cp ${S}/mcs/class/lib/monolite/* ${D}${libdir}/mono/1.0/ +} + +PACKAGES =+ "mono-dll" +FILES_mono-dll = "${libdir}/mono/1.0/" + + -- cgit v1.2.3 From 0179b6da643c30c5298bf880ced8cbb4a3bd57d0 Mon Sep 17 00:00:00 2001 From: Henryk Ploetz Date: Thu, 27 Sep 2007 20:24:22 +0000 Subject: mono-native 1.2.5.1: fix up mono native compile and make mono depend on it --- packages/mono/mono_1.2.5.1.bb | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'packages/mono/mono_1.2.5.1.bb') diff --git a/packages/mono/mono_1.2.5.1.bb b/packages/mono/mono_1.2.5.1.bb index c0a4cfb223..e1f3f1b6a5 100644 --- a/packages/mono/mono_1.2.5.1.bb +++ b/packages/mono/mono_1.2.5.1.bb @@ -1,14 +1,8 @@ require mono_1.2.5.inc -#DEPENDS = "mono-native glib-2.0" -# for now, we skip the mono-native build -- just install -# mono using your distro package manager for now -# after we get the target version working, we'll worry -# about the native package for systems that don't have mono -# installed -DEPENDS = "glib-2.0" +DEPENDS = "mono-native glib-2.0" -PR = "r0" +PR = "r1" SRC_URI += "file://configure.patch;patch=1" @@ -17,6 +11,8 @@ do_install_append() { cp ${S}/mcs/class/lib/monolite/* ${D}${libdir}/mono/1.0/ } +EXTRA_OECONF += " --disable-mcs-build " + PACKAGES =+ "mono-dll" FILES_mono-dll = "${libdir}/mono/1.0/" -- cgit v1.2.3 From bcaec55e4e64f6bca21cf0e50eaec787bd29b735 Mon Sep 17 00:00:00 2001 From: Henryk Ploetz Date: Tue, 2 Oct 2007 18:51:53 +0000 Subject: mono 1.2.5.1: added mono.bbclass, many changes required for packaging New file: packages/mono/mono-mcs-intermediate_1.2.5.1.bb Compiles mono in native mode with standard prefix, then tars up the resulting tree and puts the tarfile into staging New file: packages/mono/mono_files.py Automatically generated using collect-path.py (attached to this mail) and contains a list that maps file patterns to package names (and contained assemblies, see below). New file: classes/mono.bbclass Has a helper function for the list that maps file patterns to package names and assemblies (see below). Also has a function mono_do_clilibs and inserts that function into PACKAGEFUNCS. This function calls mono_find_provides_and_requires which finds out (through calls to monodis --assembly and monodis --assemblyref) which assemblies are provided and required by a particular package. mono_do_clilibs then puts the information about provided assemblies into ${STAGING_DIR}/clilibs/${packagename}.list and information about the required packages into ${PKGDEST}/{packagename}.clilibdeps where it will later be picked up by the modified read_shlibdeps. Originally I had dependency resolution through the partial list in mono_files.py but obviously this doens't scale, so I implemented the new method with mono_do_clilibs. The benefit is now that I don't really need the extra information in mono_files.py anymore and can in principle get rid of mono_get_file_table and related code. Instead it should be possible to modify collect-paths.py to output bitbake .inc code (e.g. PACKAGES = "..." and a whole lot of FILES_... = "...") instead of python code. There's still the minor problem of how to handle the .mdb files, that's why I didn't implement it yet but instead opted for an approach that I knew would work. (Debian just puts the .mdb files into the individual packages, while I would argue that they do belong into corresponding -dbg packages.) Modified file: classes/package.bbclass In read_shlibdeps I folded the two identical code blocks dealing with *.shlibdeps and *.pcdeps into one and added *.clilibdeps (generated by mono_do_clilibs above). Modified file: packages/mono/mono_1.2.5.1.bb Add the mono-mcs-intermediate workaround. Add a whole lot of python code in populate_packages_prepend in order to split up the packages based on information from mono_files.py (via mono.bbclass' mono_get_file_table). As I said above a lot of this code can hopefully be replaced in the future. --- packages/mono/mono_1.2.5.1.bb | 140 +++++++++++++++++++++++++++++++++++++++--- 1 file changed, 133 insertions(+), 7 deletions(-) (limited to 'packages/mono/mono_1.2.5.1.bb') diff --git a/packages/mono/mono_1.2.5.1.bb b/packages/mono/mono_1.2.5.1.bb index e1f3f1b6a5..53a671cd74 100644 --- a/packages/mono/mono_1.2.5.1.bb +++ b/packages/mono/mono_1.2.5.1.bb @@ -1,19 +1,145 @@ require mono_1.2.5.inc -DEPENDS = "mono-native glib-2.0" +DEPENDS = "mono-native mono-mcs-intermediate glib-2.0" -PR = "r1" +PR = "r2" SRC_URI += "file://configure.patch;patch=1" +# Per http://www.mono-project.com/Mono:ARM +EXTRA_OECONF += " --disable-mcs-build " +# Instead, get the mcs tree from a different build (see mono-mcs-intermediate) + +do_install_prepend() { + install -d ${D} + pushd ${D} + tar -xzf ${STAGING_DIR}/share/mono-mcs/mono-mcs-${PV}.tar.gz + popd +} + do_install_append() { - install -d ${D}${libdir}/mono/1.0/ - cp ${S}/mcs/class/lib/monolite/* ${D}${libdir}/mono/1.0/ + # mono-mcs-intermediate builds and installs jay (a Yacc for Java and C#), + # however, jay is not being cross-compiled and thus only + # available for the buildhost architecture, so remove it + # entirely + pushd ${D} + rm -rf ./usr/share/man/man1/jay.1 ./usr/share/jay \ + ./usr/share/jay/README.jay \ + ./usr/bin/jay + popd + + # Not packaged with the default rules and apparently + # not used for anything + rm -rf ${D}${datadir}/mono-1.0/mono/cil/cil-opcodes.xml } -EXTRA_OECONF += " --disable-mcs-build " +inherit mono +PACKAGES = "${@" ".join([e["name"] for e in mono_get_file_table(bb.data.getVar('PV', d, 1), d) if e.has_key("name")])}" -PACKAGES =+ "mono-dll" -FILES_mono-dll = "${libdir}/mono/1.0/" +FILES_mono-doc_append = " /usr/share/libgc-mono/ " +FILES_mono = "" # Apparently this gets ignored, so I'm setting it again below +ALLOW_EMPTY_mono = "1" +RDEPENDS_mono = "mono-common mono-jit" +FILES_mono-runtime = "" +ALLOW_EMPTY_mono-runtime = "1" +RDEPENDS_mono-runtime = "mono-jit mono-gac" + +RDEPENDS_mono-jit = "mono-common" + +FILES_libmono-dev = "/usr/lib/libmono.la /usr/lib/libmono-profiler-cov.la /usr/lib/libmono-profiler-aot.la \ + /usr/lib/libMonoPosixHelper.la /usr/lib/libMonoSupportW.la" +FILES_libmono-dbg = "/usr/lib/.debug/libmono*.so.* /usr/lib/.debug/libikvm-native.so \ + /usr/lib/.debug/libMonoPosixHelper.so /usr/lib/.debug/libMonoSupportW.so" + +python populate_packages_prepend () { + def fillin_packages(): + # A lot of this code can probably be replaced with less code and some + # calls to do_split_packages + import bb, sys, os, glob, commands + + PV = bb.data.getVar('PV', d, 1) + + file_table = mono_get_file_table(PV, d) + packages_to_add = [] + + D = bb.data.getVar('D', d, 1) + if not D: return + D = D + "/" + + def classify_files(files): + normal, dev, dbg, doc = [], [], [], [] + for filename in files: + if filename.endswith(".mdb"): + dbg.append(filename) + elif os.path.basename( os.path.dirname( filename ) ) == ".debug": + dbg.append(filename) + elif filename.endswith(".pc"): + dev.append(filename) + else: + normal.append(filename) + return normal, dev, dbg, doc + + def will_strip(filename): + # From package.bbclass function runstrip + pathprefix = "export PATH=%s; " % bb.data.getVar('PATH', d, 1) + ret, result = commands.getstatusoutput("%sfile '%s'" % (pathprefix, filename)) + if "not stripped" in result: + return True + else: + return False + + def append(name, value): + oldvalue = bb.data.getVar(name, d, 1) or "" + newvalue = " ".join([oldvalue, value]) + bb.data.setVar(name, newvalue, d) + + already_covered = [] + for package in file_table: + pn = package["name"] + if package.has_key("patterns"): + files = [] + for pattern in package["patterns"]: + matching = glob.glob( D + pattern ) + for filename in matching: + if os.path.isdir(filename): + for dirpath, dirnames, filenames in os.walk(filename): + for f in filenames: + debugname = os.path.join(dirpath, ".debug", f) + fullname = os.path.join(dirpath, f) + files.append(fullname) + if will_strip(fullname): + files.append(debugname) + else: + files.append(filename) + + # Remove the D prefix + files = [ e[len(D):] for e in files ] + + # Remove files that have already been placed in other packages + files = [ e for e in files if not e in already_covered ] + already_covered.extend( files ) + + if pn.endswith("-dev") or pn.endswith("-dbg") or pn.endswith("-doc"): + normal, dev, dbg, doc = files, [], [], [] + else: + normal, dev, dbg, doc = classify_files(files) + + for extension, filelist in [ ("",normal), ("-dev", dev), ("-dbg", dbg), ("-doc", doc)]: + if len(filelist) > 0: + packagename = pn + extension + append("FILES_%s" % packagename, " ".join(filelist)) + bb.debug(2, "%s\n\t%s" %( packagename, "\n\t".join( filelist ) )) + if not packagename in packages_to_add: + packages_to_add.append(packagename) + + else: + packages_to_add.append(pn) + + # mono is just a stub package + bb.data.setVar("FILES_mono", "", d) + + bb.data.setVar("PACKAGES", " ".join(packages_to_add), d) + fillin_packages() +} -- cgit v1.2.3 From 493a9dae7b8d0f0d1e05901bceaa48132c9d2c3e Mon Sep 17 00:00:00 2001 From: Cliff Brake Date: Wed, 3 Oct 2007 17:10:04 +0000 Subject: mono 1.2.5.1: add perl-native to DEPENDS --- packages/mono/mono_1.2.5.1.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'packages/mono/mono_1.2.5.1.bb') diff --git a/packages/mono/mono_1.2.5.1.bb b/packages/mono/mono_1.2.5.1.bb index 53a671cd74..9a3d4971fd 100644 --- a/packages/mono/mono_1.2.5.1.bb +++ b/packages/mono/mono_1.2.5.1.bb @@ -1,6 +1,6 @@ require mono_1.2.5.inc -DEPENDS = "mono-native mono-mcs-intermediate glib-2.0" +DEPENDS = "mono-native mono-mcs-intermediate glib-2.0 perl-native" PR = "r2" -- cgit v1.2.3 From 28bbfa1c1ce42dfd54653330f59e1a11b6456371 Mon Sep 17 00:00:00 2001 From: Henryk Ploetz Date: Wed, 3 Oct 2007 20:59:46 +0000 Subject: mono 1.2.5.1: patch genmdesc.pl to use cpp from staging instead of host --- packages/mono/mono_1.2.5.1.bb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'packages/mono/mono_1.2.5.1.bb') diff --git a/packages/mono/mono_1.2.5.1.bb b/packages/mono/mono_1.2.5.1.bb index 9a3d4971fd..c3ea1818ad 100644 --- a/packages/mono/mono_1.2.5.1.bb +++ b/packages/mono/mono_1.2.5.1.bb @@ -4,7 +4,8 @@ DEPENDS = "mono-native mono-mcs-intermediate glib-2.0 perl-native" PR = "r2" -SRC_URI += "file://configure.patch;patch=1" +SRC_URI += "file://configure.patch;patch=1 \ + file://genmdesc-cpp.patch;patch=1" # Per http://www.mono-project.com/Mono:ARM EXTRA_OECONF += " --disable-mcs-build " -- cgit v1.2.3