It was <2013-11-08 pią 06:27>, when Dong, Junfeng wrote: > -----Original Message----- > From: Łukasz Stelmach [mailto:[email protected]] > Sent: Friday, November 08, 2013 12:44 AM >> It was <2013-11-07 czw 12:16>, when Kanevskiy, Alexander wrote: >>> On 07/11/13 05:59 , "Jian-feng Ding" <[email protected]> wrote: >>> >>>>Oh, that's really a good news. The reason of so many prepackages in >>>>ks is the plenty of packaging errors in original tizen packages. If >>>>all the errors are fixed, the prepackages can be cleaned up in >>>>theory. >>> >>> it is not “in theory”. PrePackages must be avoided from use in 3.0 >>> in practice. >>> >> I was experimenting with mic just a moment ago. I used ks file with >> prepackages and, of course, I got into trouble (notice the >> lib;527bba47 link below) >> >> --8<---------------cut here---------------start------------->8--- >> lrwxrwxrwx 1 root root 7 lis 7 17:05 bin -> usr/bin >> dr-xr-xr-x 2 root root 4096 lis 5 20:22 boot >> drwxr-xr-x 3 root root 4096 lis 5 20:22 dev >> drwxr-xr-x 23 root root 4096 lis 7 17:05 etc >> drwxr-xr-x 2 root root 4096 lis 5 20:22 home >> drwxr-xr-x 2 root root 4096 lis 7 17:05 lib >> lrwxrwxrwx 1 root root 7 lis 7 17:05 lib;527bba47 -> usr/lib >> drwx------ 2 root root 16384 lis 7 17:00 lost+found >> drwxr-xr-x 8 root root 4096 lis 7 17:05 opt >> dr-xr-xr-x 214 root root 0 lis 5 20:22 proc >> drwxr-xr-x 2 root root 4096 lis 7 17:05 run >> drwxr-xr-x 13 root root 0 lis 4 10:19 sys >> drwxr-xr-x 6 root root 4096 lis 7 17:05 usr >> drwxr-xr-x 5 root root 4096 lis 7 17:04 var >> --8<---------------cut here---------------end--------------->8--- >> >> The invalid link comes from a failed instalation of the filesystem >> package. >> >> --8<---------------cut here---------------start------------->8--- >> INFO: Installing: filesystem [ >> 8/583] >> error: unpacking of archive failed on file /lib: cpio: rename failed - Is a >> directory >> error: filesystem-3.1-3.1.armv7l: install failed >> --8<---------------cut here---------------end--------------->8--- >> >> Although removal of the prepackages from meta-mobila package and the >> ks file helps (as Jacek reports) and the filesystem package is >> instaled before any other package tries to install something in /lib >> or other directories provided by the filesystem package as links, >> >> --8<---------------cut here---------------start------------->8--- >> lrwxr-xr-x 1 root root 7 Nov 5 20:22 ./bin -> usr/bin >> lrwxr-xr-x 1 root root 7 Nov 5 20:22 ./lib -> usr/lib >> lrwxr-xr-x 1 root root 8 Nov 5 20:22 ./sbin -> usr/sbin >> lrwxr-xr-x 1 root root 10 Nov 5 20:22 ./usr/tmp -> >> ../var/tmp >> lrwxr-xr-x 1 root root 10 Nov 5 20:22 ./var/mail -> >> spool/mail >> --8<---------------cut here---------------end--------------->8--- >> >> we still have no guarantee this won't break in the future. What we've >> got is a kind of a race condition. We need to *force* the filesytem >> package to be installed as the very first. Would renaming the rpm to >> something like aaa_filesystem help? > > [Junfeng] Base on my understanding, the order of > Setup->filesystem->glibc is critical.
It certainly is. However, filesystem is the fifth package installed (with prepackages removed from the ks file). --8<---------------cut here---------------start------------->8--- INFO: Installing: boost-license [ 1/583] INFO: Installing: terminfo-base [ 2/583] INFO: Installing: hwdata [ 3/583] INFO: Installing: setup [ 4/583] INFO: Installing: filesystem [ 5/583] --8<---------------cut here---------------end--------------->8--- boost-license is completely empty. terminfo-base and hwdata do not contain anything in the symlinked directories. These three packages most probably won't brake anthing. > Such relation is defined by the "Require:" in spec file. And almost > all in /lib requires "glibc", that makes "filesystem" is guaranteed to > be installed before other packages. Even there is still some race > condition, solving the problem by defining "requires:" in spec fie is > a better solution than a new package in "prepackage". In theory this works. Unfortunately, the three packages that are installed before setup make me worry that it is *possible* for another random package that *may* contain something in the symlinked directories to go before setup and filesystem. The package dependencies create a DAG[1] and it is up to the installer to find the loose end and start there. If a package in a set does not have any dependencies (like the three above) we can't be sure it won't go first. And we MUST be sure. I took a look at Debian's deboostrap[2] package. It looks like they have some packagenames *hardcoded*[3] in the scripts to be installed before everything else. They are: dpkg, base-files (equivalent of our filesystem and setup), base-passwd, C library, perl awk and debconf. Only after these are in place the packages listed in configutation files are installed. It appears we may need prepackages or anything alse that [1] http://en.wikipedia.org/wiki/Directed_acyclic_graph [2] http://anonscm.debian.org/gitweb/?p=d-i/debootstrap.git [3] http://anonscm.debian.org/gitweb/?p=d-i/debootstrap.git;a=blob;f=scripts/sid;h=0e2c12d37d8f8dd40ef9d7be17ac348ac7e2e0d1;hb=c3ab42b4c7d3880b97af8172177a26a7c5b2c8fb#l101 -- Łukasz Stelmach Samsung R&D Institute Poland Samsung Electronics
pgp61VA6u2l2X.pgp
Description: PGP signature
_______________________________________________ Dev mailing list [email protected] https://lists.tizen.org/listinfo/dev
