[ELDK] Rebuilding python ELDT package
mfuchs at ma-fu.de
Sat Jul 4 11:56:03 CEST 2009
I am trying to build - modify - build again the ELDT python RPM package.
I am using the latest tarball and spec file from the Denx git repositories.
The initial build as described on http://www.denx.de/wiki/view/DULG/ELDKRebuildingComponents
works fine. Good work.
But now I want to modify the python source and rebuild - but without doing the
complete rpmbuild. Because I am not an RPM expert I google'd and
found this recipe - still thinking this should be the same as "rpmbuild -ba"
1) Prepare the sources (unpack tarball etc.):
ppc_4xx-rpmbuild -bp python.spec
2) Modify sources (or not)
3) start at build stage
ppc_4xx-rpmbuild -bc --short-circuit python.spec
But now I get:
b.h: found (4, 5) in /opt/eldk_420/ppc_4xx/usr/include
db lib: using (4, 5) db-4.5
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for gcc... ppc-linux-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details.
Failed to configure _ctypes module
/opt/eldk_420/usr/src/denx/BUILD/Python-2.5.1/Modules/readline.c: In function 'flex_complete':
/opt/eldk_420/usr/src/denx/BUILD/Python-2.5.1/Modules/readline.c:681: warning: return makes pointer from integer without a cast
+ exit 0
Q1: Is there any difference between
ppc_4xx-rpmbuild -ba python.spec
ppc_4xx-rpmbuild -bp python.spec; ppc_4xx-rpmbuild -bc --short-circuit python.spec ?
Q2: I noticed that during the complete build (-ba) I always get two configure runs (hostpython + target's python). This is correct. But the spec file seems to take take of the case when hostpython and hostpgen
already exist from a previous build. This check does not work. I had to modify the spec file
to use $topdir instead of $RPM_BUILD_DIR:
if [ ! -e $topdir/hostpython -a ! -e $topdir/Parser/hostpgen ]; then \
if [ -e $topdir/Makefile ]; then $(MAKE) -C $topdir distclean; fi; \
Am I missing something or is this a bug in the spec file?
More information about the eldk