[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Ltib] Trouble adding new package in LTIB
From: |
James E. Chargin Jr. |
Subject: |
Re: [Ltib] Trouble adding new package in LTIB |
Date: |
Thu, 14 Aug 2008 09:07:32 -0700 |
User-agent: |
Thunderbird 2.0.0.16 (Windows/20080708) |
Peter,
Thanks for the help. Based on the information you gave, I've made progress.
I was going to use .gz because the first two steps in the FAQ use .gz
and don't mention .bz2. I made this choice before noticing in the
specfile that .bz2 is supported.
Today, I used the .bz2 directly from GNU, using your instructions.
Today, I also noticed that your instructions regarding modifications to
packages.lkc and pkg_map are mentioned in a later FAQ. Since I'm really
a novice to packaging systems, I did not make the connection between the
two FAQs. Perhaps the FAQ regarding "How can I add a completely new
package..." should mention the FAQ "How do I introduce my new package to
the config system".
Anyway, once I made additions to packages.lkc and pkg_map as you
suggest, the following command worked:
./ltib -m prep -p parted.spec
If I specified parted, rather than parted.spec, the specfile was not
found. Even though the command worked, it did emit some error messages,
which I ignored. The rpmbuild seemed to work so I'm not sure the
messages about network connections are important to me (for now).
8--
> ./ltib -m prep -p parted.spec
Processing platform: Freescale MPC8315E RDB PowerPC board
===========================================================
using config/platform/mpc8315erdb/.config
Processing: parted
====================
Testing network connectivity
Testing proxy connection for GPP : FAIL
response was: 500 Can't connect to wwwgate0.freescale.net:1080 (Bad
hostname 'wwwgate0.freescale.net')
Can't get gpp index, proxy forced off
FAILED PPP: : 500 Can't connect to auslxsc01.mtwk.freescale.net:80 (Bad
hostname 'auslxsc01.mtwk.freescale.net')
OK GPP:
FAILED GPP: parted-1.8.8.tar.bz2.md5: 404 Not Found
WARN: skipping md5sum check for
/opt/freescale/pkgs/parted-1.8.8.tar.bz2, md5 file was not found
rpmbuild --dbpath /home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/rpmdb
--define '_unpackaged_files_terminate_build 0' --define '_target_cpu
powerpc' --define '__strip strip' --define '_topdir
/home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/rpm' --define '_prefix
/usr' --define '_tmppath
/home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/tmp' --define '_mandir
/usr/share/man' --define '_sysconfdir /etc' --define '_localstatedir
/var' -bp
/home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1/parted/parted.spec
rpmbuild --dbpath /home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/rpmdb
--define _unpackaged_files_terminate_build 0 --define _target_cpu
powerpc --define __strip strip --define _topdir
/home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/rpm --define _prefix /usr
--define _tmppath /home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/tmp
--define _mandir /usr/share/man --define _sysconfdir /etc --define
_localstatedir /var -bp
/home/jimc/borg/ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1/parted/parted.spec
...
--8
((
Vadim:
I didn't mention in my original report that once
./ltib -m prep -p parted
failed, based on the error message, I had tried
./ltib -m prep -p parted.spec
and
./ltib -m prep -p \
.../ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1/parted/parted.spec
These commands gave the same error as when I didn't specify .spec so I
didn't mention these attempts.
))
My next problem is with the step
7. Build the new package with your changes:
./ltib -m scbuild -p parted.spec
After much output, I get the message:
8--
configure: error: termcap could not be found which is required for the
--with-readline option (which is enabled by default). Either disable
readline support with --without-readline or download and install termcap
from:
ftp.gnu.org/gnu/termcap
Note: if you are using precompiled packages you will also need the
development package as well (which may be called termcap-devel or
something similar).
Note: (n)curses also seems to work as a substitute for termcap. This
was not found either - but you could try installing that as well.
--8
I would prefer (I think) to build without termcap, rather than include
it on my embedded system, but I don't know where I would specify
--without-readline. I know this would be a command line parameter for
configure, but I don't know where that command line is generated.
Could you (or anyone) provide guidance?
Thanks
Jim
Peter Barada wrote:
On Wed, 2008-08-13 at 10:19 -0700, James E. Chargin Jr. wrote:
I'm using LTIB on Ubuntu 7.10, targeting the MPC8315e.
Since I've determined that GNU parted is not currently available for
LTIB, I'm attempting to port parted so it is available on our target.
I've followed the instructions in the LTIB FAQ as best I can but am
getting an error that I can't find an explanation for.
I downloaded parted-1.8.8.tar.bz2 from fsf. I unpacked it so I could
later tar it to .gz as is expected by the instructions in the FAQ.
Hmm, then the FAQ is wrong since it supports .bz2 (as specified in your
.spec file 'Source' further on).
So, starting with section "How can I add a completely new package to the
root filesystem" in the LTIB FAQ:
1. First clean your sources...
Since I had just downloaded and untarred the package, I did not "make
clean". I executed "tar zcvf parted-1.8.8.tar.gz parted-1.8.8"
2. Move this tarball...
I executed "cp parted-1.8.8.tar.gz /opt/freescale/pkgs/
3; Create a specfile...
I executed:
cd .../ltib/ltib-mpc8315erdb-20071129
mkdir dist/lfs-5.1/parted
cp dist/lfs-5.1/template/template.spec dist/lfs-5.1/parted/parted.spec
4: Edit and fixup the template...
My edited specfile is:
8--
%define pfx /opt/freescale/rootfs/%{_target_cpu}
Summary : GNU parted - partition editor
Name : parted
Version : 1.8.8
Release : 1
License : GPL
Vendor : Free Software Foundation
Packager : xxxx
Group : xxxx
URL : http://directory.fsf.org/project/parted/
Source : %{name}-%{version}.tar.bz2
BuildRoot : %{_tmppath}/%{name}
Prefix : %{pfx}
%Description
%{summary}
%Prep
%setup
%Build
./configure --prefix=%{_prefix} --host=$CFGHOST --build=%{_build}
make
%Install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT/%{pfx}
%Clean
rm -rf $RPM_BUILD_ROOT
%Files
%defattr(-,root,root)
%{pfx}/*
--8
5. Unpack the new package source:
Here is where I encounter the error. When I execute "./ltib -d -m prep
-p parted" (I am dry-running to see what it will do), I see the message:
8--
Cannot find spec file that contains the package name parted.
If necessary please give the whole spec file name (with the
.spec extension).
Exiting on error or interrupt
--8
I tried various commands trying to give the full specfile pathname, with
no success. The last command I tried was "./ltib -d -m prep -p
.../ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1/parted/parted.spec" (I
tried this with sudo also). I got the error message:
8--
get_spec: can't find spec file
.../dist/ltib-mpc8315erdb-20071129/lfs-5.1/parted/parted.spec
in search any of the directories:
.../ltib/ltib-mpc8315erdb-20071129/rpm/SPECS
.../ltib/ltib-mpc8315erdb-20071129/config/platform/mpc8315erdb
.../ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1
Processing platform: Freescale MPC8315E RDB PowerPC board
===========================================================
using config/platform/mpc8315erdb/.config
Processing: .../dist/lfs-5.1/parted/parted
=======================================================================================
skipping .../ltib/ltib-mpc8315erdb-20071129/dist/lfs-5.1/parted/parted,
specfile not found
f_prep() returned an error, exiting
Exiting on error or interrupt
--8
It seems I'm doing something basic incorrectly, but I can't see what it
might be.
Any suggestions?
Add to config/userspace/packages.lkc a stanza to allow selection of
parted, preferably in alphabetical order:
config PKG_PARTED
bool "parted"
help
partition manipulation tool
Then add to dist/lfs-5.1/common/pkg_map
PKG_PARTED = parted
This should get "./ltib -p parted" to find the spec file.
Hope this helps...
Thanks,
Jim
--
Peter Barada <address@hidden <mailto:address@hidden>>
- [Ltib] Trouble adding new package in LTIB, James E. Chargin Jr., 2008/08/13
- Re: [Ltib] Trouble adding new package in LTIB, Peter Barada, 2008/08/13
- Re: [Ltib] Trouble adding new package in LTIB,
James E. Chargin Jr. <=
- Re: [Ltib] Trouble adding new package in LTIB, Stuart Hughes, 2008/08/14
- Re: [Ltib] Trouble adding new package in LTIB, Peter Barada, 2008/08/14
- Re: [Ltib] Trouble adding new package in LTIB, Stuart Hughes, 2008/08/15
- Re: [Ltib] Trouble adding new package in LTIB, James E. Chargin Jr., 2008/08/15
- Re: [Ltib] Trouble adding new package in LTIB, Luis Felipe Strano Moraes, 2008/08/15
- Re: [Ltib] Trouble adding new package in LTIB, James E. Chargin Jr., 2008/08/15
- Re: [Ltib] Trouble adding new package in LTIB, Stuart Hughes, 2008/08/18
- Re: [Ltib] Trouble adding new package in LTIB, James E. Chargin Jr., 2008/08/18
- Re: [Ltib] Trouble adding new package in LTIB, Stuart Hughes, 2008/08/18
- Re: [Ltib] Trouble adding new package in LTIB, Vadim Lebedev, 2008/08/13