POV-Ray / povray

The Persistence of Vision Raytracer: http://www.povray.org/
GNU Affero General Public License v3.0
1.35k stars 282 forks source link

cross build support #388

Open anbe42 opened 4 years ago

anbe42 commented 4 years ago

quoting from https://bugs.debian.org/946477

povray fails to cross build from source, because it uses AC_RUN_IFELSE in a few places. Getting rid of these isn't obvious. It's used for different things:

  • Checking whether boost thread works. -> AC_LINK_IFELSE suffices here.
  • Determining versions of libraries. -> AC_COMPUTE_INT often works.
  • Determining version of libtiff. -> We can opportunistically use PKG_CHECK_MODULES and fall back to the old check on failure.

Together these changes make povray cross buildable. We're not the first ones attempting to do so. OpenEmbedded has tried earlier: https://github.com/openembedded/openembedded/blob/master/recipes/povray/povray-3.6.1%2B3.7.0-beta25b/configure-cross-hack.patch Their patch is not suitable for upstream inclusion, but I think this one is. Please consider applying it. Doing so would help other distributions as well.

Helmut

Helmut's patch (for 3.7.0) is available at https://bugs.debian.org/cgi-bin/bugreport.cgi?att=1;bug=946477;filename=cross.patch;msg=5

Please also update the embedded copies of the autoconf macros (unix/config/*.m4) to the latest upstream versions to get any fixes/improvements that may have been applied upstream inbetween. (See https://bugs.debian.org/945259 for details on a cross building issue caused by an outdated AX_BOOST_BASE.)

Andreas

wfpokorny commented 4 years ago

Hi Andreas, The core POV-Ray maintainers have not been active since a little before mid year. I have a few times since tried to capture in a branch relatively complete updates others have worked up and reading through the bugs.debian.org links you've provided it looks like you did this for POV-Ray v3.7.0.8.

I know a naive question, but could you provide a direct link (or method ftp?) to your updated povray_3.7.0.8-2.debian.tar.xz ? A quick search via google just now didn't turn it up.

I'll put it on my list to try and work up fix branches for v.3.7.0 - and the working v.3.8 master branch - based upon your updates. I've very little time myself for hobby work until perhaps mid January or so, but will try to get to branches for these fixes after that. I noted Hemut's comments about not duplicating the M4 files as a practice too so will look into that too as a general thing. Unsure why such duplication was originally done though as you noted POV-Ray has some unique M4 files.

Thanks to you (and Helmet) for your work here. I'll try and at least capture your work in branches which maintainers when they return - or others - can simply merge.

anbe42 commented 4 years ago

@wfpokorny :

I know a naive question, but could you provide a direct link (or method ftp?) to your updated povray_3.7.0.8-2.debian.tar.xz ? A quick search via google just now didn't turn it up.

The Debian packaging can be found in the git repository at https://salsa.debian.org/debian/povray The .debian.tar.xz is just a snapshot of the debian/ folder in that repository at the time an upload to Debian happened. (The .debian.tar.xz is only a supplement to the pristine upstream povray_3.7.0.8.orig.tar.gz tarball (which was the archive downloaded from github for the corresponding tag)).) What would be most interesting to you is the content of the debian/patches/ folder - but note: not every patch is suitable for upstream inclusion, some are just adaptations (e.g. path adjustments) needed for Debian integration.

Andreas

wfpokorny commented 3 years ago

Update. Helmut's cross compile build support changes can be seen directly at:

https://sources.debian.org/src/povray/1:3.7.0.8-5/debian/patches/cross.patch/

These, the suggested update to a new version of ax_boost_base.m4 and many more build system updates will be in the next tar ball for my v3.8 povr branch of POV-Ray. I think most of the changes would map back in a workable way to the v3.8 master branch as it stands today - should others be interested.

c-lipka commented 3 years ago

For the records: I'll say cross-compilation is not high enough on our agenda to tackle it for the v3.8.0 release proper, but I'd also like to think it is high enough on our agenda to tackle it later in a maintenance release (e.g. some v3.8.0.1), not just the v4.0 branch.