Makefile is written for Linux. When you build on Gentoo/FreeBSD, three problems occur. * cp --remove-destination is not supported on FreeBSD. * GNU make command name is gmake on Gentoo/FreeBSD. * FreeBSD's install command is not supported -D option. In addition, the following two error is displayed also on Linux. /var/tmp/portage/sys-power/iasl-20120816/temp/environment: line 2345: cd: acpica/generate/unix: No such file or directory * QA Notice: make jobserver unavailable: * * gmake[1]: warning: jobserver unavailable: using -j1. Add `+' to parent make rule. I'll attach sample patch. FYI, error list on G/FBSD gmake -j5 BITS=64 "Makefile", line 24: Need an operator make: fatal errors encountered -- cannot continue cp: illegal option -- - usage: cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file target_file cp [-R [-H | -L | -P]] [-f | -i | -n] [-alpvx] source_file ... target_directory install -D ../bin64/iasl /var/tmp/portage/sys-power/iasl-20120816/image//usr/bin/iasl install: illegal option -- D usage: install [-bCcMpSsv] [-B suffix] [-f flags] [-g group] [-m mode] [-o owner] file1 file2 install [-bCcMpSsv] [-B suffix] [-f flags] [-g group] [-m mode] [-o owner] file1 ... fileN directory install -d [-v] [-g group] [-m mode] [-o owner] directory ... Reproducible: Always Steps to Reproduce: 1. emerge sys-power/iasl 2. 3.
Created attachment 333276 [details, diff] sample patch for iasl-20120816.ebuild
Comment on attachment 333276 [details, diff] sample patch for iasl-20120816.ebuild >--- iasl-20120816.ebuild.orig 2012-09-08 08:11:29.000000000 +0900 >+++ iasl-20120816.ebuild 2012-12-25 21:15:00.000000000 +0900 >@@ -48,8 +48,22 @@ > xargs -0 -I '{}' \ > sed -r -e 's:-\<Werror\>::g' -i '{}' \ > || die >+ if use userland_BSD ; then >+ find "${S}/generate/unix" -type f -name 'Makefile*' -print0 | \ >+ xargs -0 -I '{}' \ >+ sed -r -e 's:make BITS=:gmake BITS=:g' \ This should use $(MAKE) instead. Makefiles should always be fixed to use it. >+ -e 's:--remove-destination:-f:g' -i '{}' \ IMHO, we may use "-f" always (not specific on Linux), since we are building the code in separated directory. >@@ -57,8 +71,8 @@ > } > > src_compile() { >- cd acpica/generate/unix >- emake BITS=${BITS} >+ cd "${S}"/generate/unix >+ emake -j1 BITS=${BITS} This line can be preserved if we patch the code to use $(MAKE) > } > > src_test() { >@@ -68,9 +82,14 @@ > } > > src_install() { >- cd acpica/generate/unix >- emake install DESTDIR="${D}" BITS=${BITS} >- default_src_install >+ if use userland_BSD ; then >+ cd "${S}"/generate/unix/bin${BITS} >+ dobin * >+ else >+ cd "${S}"/generate/unix >+ emake install DESTDIR="${D}" BITS=${BITS} >+ default_src_install >+ fi I'd prefer to patch the code to do "portable" install usage.
Now, sys-power/iasl-20171215 can compile on Gentoo/FreeBSD. closing.