-source build-dep not needed when building cross-compilers

Bug #593187 reported by Loïc Minier
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gcc-4.4 (Ubuntu)
Won't Fix
Undecided
Unassigned
gcc-4.5 (Ubuntu)
Won't Fix
Undecided
Unassigned

Bug Description

Binary package hint: gcc-4.4

Hi

In 4.4.2-1:
  * GCC 4.4.2 release.
    - Fixes PR target/26515, PR target/41680, PR rtl-optimization/41646,
      PR c++/39863, PR c++/41038.
  * Fix setting timeout for testsuite runs.
  * gcj-4.4/gcc-snapshot: Drop build-dependency on libgconf2-dev, disabled
    by default.
  * gcj-4.4: Run the libffi testsuite as well.
  * Add explicit build dependency on zlib1g-dev.
  * Fix cross builds, add support for gomp and gfortran (only tested for
    non-biarch targets).
  * (Build-)depend on binutils-2.20.
  * Fix up omp.h for multilibs (taken from Fedora).

these lines were added:
SOURCE_BUILD_DEP :=
ifeq (,$(findstring gcc,$(PKGSOURCE)))
  SOURCE_BUILD_DEP := gcc-$(BASE_VERSION)-source (>= $(GCC_SOURCE_VERSION)), gcc-$(BASE_VERSION)-source (<< $(NEXT_GCC_SOURCE_VERSION)),
endif

This seems to break my cross-compiler buils. I don't think I need gcc-4.4-source to build a gcc-4.4 cross-compiler (host == build != target), but perhaps it's needed for other cases?

Thanks,

Revision history for this message
Loïc Minier (lool) wrote :

Sorry, pasted the wrong snippet of rules.conf, this is the one adding the build-dep:
else
# build cross compiler
  CROSS_BUILD_DEP := libc6-dev$(cross_lib_arch), zlib1g-dev$(cross_lib_arch), libmpfr-dev$(cross_lib_arch),
  SOURCE_BUILD_DEP := gcc-$(BASE_VERSION)-source (>= $(GCC_VERSION)), gcc-$(BASE_VERSION)-source (<< $(NEXT_GCC_VERSION)),

Revision history for this message
Matthias Klose (doko) wrote :

no, the cross-source package must not have a copy of the sources.

Changed in gcc-4.4 (Ubuntu):
status: New → Invalid
Changed in gcc-4.5 (Ubuntu):
status: New → Invalid
Revision history for this message
Loïc Minier (lool) wrote :

This is not about the cross-source packages, but about the build-deps on the source packages; this creates a build-dep on the same source package, so it means two builds to create cross-compilers from new gcc-ish sources (one native and one with debian/target set), just to get the gcc-*-source binary packages.

Changed in gcc-4.4 (Ubuntu):
status: Invalid → New
Changed in gcc-4.5 (Ubuntu):
status: Invalid → New
Revision history for this message
Loïc Minier (lool) wrote :

(I just checked and a build of a cross-compiler does not output -source packages.)

Revision history for this message
Matthias Klose (doko) wrote :

a gcc-4.4-cross-<something> source package has to build-depend on the gcc-4.4-source package. It must not duplicate the tarball inside the source package. The build-dependency on the gcc-4.4-source is needed. Wether the patches and rules files are used from the gcc-4.4-source binary package, or the gcc-4.4-cross-<something> source package is up to the gcc-4.4-cross-<something> source package.

Changed in gcc-4.4 (Ubuntu):
status: New → Incomplete
Revision history for this message
Loïc Minier (lool) wrote :

Ok; I understand the reasoning; it's a pain when one is just cross-building a real gcc-4.4 tree (which already has the source!), so I guess we could add the build-dep only if the package is not exactly gcc-4.x or something like that.

Revision history for this message
Matthias Klose (doko) wrote :

while cross-building a real gcc-4.4 tree you could pass the -d option to dpkg-buildpackage after checking that other build dependencies are fulfilled. The use case above is only meant for local hacks/builds. It's not appropriate for package uploads.

Changed in gcc-4.5 (Ubuntu):
status: New → Won't Fix
Changed in gcc-4.4 (Ubuntu):
status: Incomplete → Won't Fix
Revision history for this message
Loïc Minier (lool) wrote :

I see your point, albeit it's not easy to tell xdeb to pass -d for instance; people could indeed build the package by hand though, it just seemed nice to avoid the hassle.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related blueprints

Remote bug watches

Bug watches keep track of this bug in other bug trackers.