no waf maintainer so i am putting this out here for
discussion.

right, so mpv in their next release switched from the
mplayer inherited custom configure/gmake build system
to waf.  good move? at first glance yes, as probably
anything is better then gnu autotools.

unfortunately waf is a python program the kind of i
have never seen before. the "waf" file contains a bzip2
stream containing the python library files that are
extracted upon running into a hidden directory where
the waf executable resides (so having a single
/usr/local/bin/waf and running that in the project
directory is a no go, as it will try to extract to
/usr/local/bin/.waf-* and not $PWD)

furthermore waf is hostile to packaging (there is in an
ancient version in the ports), su much so, that the
install target has been removed and the "waf book"
clearly states that the preferred modus operandi is to
put the waf file into the project directory.

this wouldnt be such an issue if all the projects using
it would simply have it in their release archives. this
is not the case. mpv provides a "bootstrap.py" file
that downloads their preferred version.

some possible solutions:

1. post-extract runs bootsrap.py (python is already a
   dependency anyway)

2. post-extract copies files/waf to ${WRKDIST}

3. patch waf so it tries to unpack into $PWD
   (${WRKDIST}) instead of where the waf file resides.

4. update the waf port, but this is a can of worms as
   a) it "does not want" to be packaged
   b) probably breaks all other projects using waf that
      do not contain their own copy, in other words
      the port would have to contain every single waf
      version and BUILD_DEPENDS would pull in the
      correct version the project has been tested with.

no 3 seems like an elegant solution (intead of trying
to shoehorn waf into site-packages) and the problem of
multiple versions for multiple ports could be solved by
making a waf package that contains every single waf
version (that are used by ports atm) and pulling in the
good version somehow in the makefile.  so the package
would install:

/usr/local/bin/waf-a.b.c
/usr/local/bin/waf-d.e.f
...

and with that frankenstein idea i wish everyone a happy
new bsd year.

-f
-- 
"give me two personal pronouns." "who, me?" -- benny hill

Reply via email to