Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upGif2apng #894
Gif2apng #894
Conversation
|
There are a couple of things to change. I'm writing a review. |
|
Changes to allow installation to bin/ instead of bin/x86/. BTW, you added a patch but you did not reference it. I guess it was for x86_gcc2 only. |
|
|
||
| PROVIDES=" | ||
| gif2apng$secondaryArchSuffix = $portVersion | ||
| cmd:gif2apng$secondaryArchSuffix = $portVersion |
This comment has been minimized.
This comment has been minimized.
fbrosson
Nov 30, 2016
Member
Then we drop the $secondaryArchSuffix from cmd:gif2apng$secondaryArchSuffix to let haikuporter know that it should not expect anything in $prefix/bin/x86/, since we're installing to $prefix/bin/.
You should therefore have:
cmd:gif2apng = $portVersion
| INSTALL() | ||
| { | ||
| mkdir -p $binDir | ||
| mv gif2apng $binDir |
This comment has been minimized.
This comment has been minimized.
fbrosson
Nov 30, 2016
Member
Should be:
mkdir -p $commandBinDir
cp gif2apng $commandBinDir
The reason why we prefer using cp instead of mv is that mv would break haikuporter -F.
|
|
||
| ARCHITECTURES="x86 x86_64" | ||
| SECONDARY_ARCHITECTURES="x86" | ||
|
|
This comment has been minimized.
This comment has been minimized.
fbrosson
Nov 30, 2016
Member
If a recipe does not build on x86_gcc2 primary arch then we usually install to $prefix/bin instead of $binDir (which is $prefix/bin/x86 on x86 secondary arch).
For that purpose we define commandBinDir with these lines between SECONDARY_ARCHITECTURES and PROVIDES:
if [ "$targetArchitecture" != x86_gcc2 ]; then
commandBinDir=$binDir
else
commandBinDir=$prefix/bin
fi
(You can copy that block from haikuports/media-video/dvdauthor/dvdauthor-0.7.1.recipe)
This comment has been minimized.
This comment has been minimized.
|
Doesn't it have a make install ? |
|
@mmuman no, just generates the binary in the main directory. no install task defined in the makefile |
|
Ok then. |
|
Cosmetic changes for DESCRIPTION and SOURCE_URI. |
| @@ -0,0 +1,44 @@ | |||
| SUMMARY="Converts GIF animations into APNG format" | |||
| DESCRIPTION="This program converts GIF animations into animated PNG format. \ | |||
| Usually it makes the files smaller. CLI version is OS-independent." | |||
This comment has been minimized.
This comment has been minimized.
| COPYRIGHT="2009-2013 Max Stepin" | ||
| LICENSE="Zlib" | ||
| REVISION="1" | ||
| SOURCE_URI="https://sourceforge.net/projects/gif2apng/files/$portVersion/gif2apng-$portVersion-src.zip" |
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
I forgot to suggest a slightly better SOURCE_URI:
SOURCE_URI="https://downloads.sourceforge.net/gif2apng/gif2apng-$portVersion-src.zip"
|
just pushed updates @fbrosson. Thoughts? |
|
Sorry for the delay. I was trying to build on x86_gcc2 primary arch with a variant of your patch.
in order to be able to have this in BUILD:
Unfortunately it does not work: I get
So I guess the best option is to drop x86_gcc2 as primary arch. (That's what you did ;-)
or
(I think we should have the |
|
@fbrosson yeah, that was the error I kept running into with GCC2. the issue is that zopfli requires later than GCC4. might just not include the x86_gcc2 for that reason, but up to you. |
| else | ||
| commandBinDir=$prefix/bin | ||
| fi | ||
| echo $commandBinDir |
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
It would be better without the echo $commandBinDir ;-)
Everything else looks OK. I'll build it on each of my architectures and then merge.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
While at it, can you also change ARCHITECTURES to:
ARCHITECTURES="!x86_gcc2 x86 x86_64"
Thanks!
This comment has been minimized.
This comment has been minimized.
72f5e81
to
0b8d4ed
|
okay, now it's fixed. |
| commandBinDir=$prefix/bin | ||
| fi | ||
| mkdir -p $commandBinDir | ||
| cp gif2apng $commandBinDir |
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
Maybe we should simplify INSTALL to have only:
INSTALL()
{
mkdir -p $prefix/bin
cp gif2apng $prefix/bin
}
I had suggested defining commandBinDir because we often do that, but since we don't even use it in BUILD (for this recipe) it does not really make sense to define commandBinDir just for INSTALL. Moreover, we just use it twice. (So sorry for the bad suggestion...)
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
Great. Thanks! I'll validate your task asap.
Then I'll build the recipe on x86 and x86_64 before I merge.
| BUILD_PREREQUIRES=" | ||
| cmd:gcc$secondaryArchSuffix | ||
| cmd:make | ||
| cmd:automake |
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
It builds fine without cmd:automake so it would be nice to remove that dependency. Thanks!
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
fbrosson
Dec 1, 2016
Member
Yes, it's perfect ;-)
To HaikuPorts members: If you merge, please don't forget to schrink the commit message.
But don't worry. I'll merge it myself as soon as I have built it on all architectures.
zopfli does not work with gcc2 added secondary arch fixed bin dir not existing Fixed by suggestions from fbrosson removed debug echo line arch removed binDir Removed automake dep
|
On Wed, Nov 30, 2016 at 05:41:01PM -0800, fbrosson wrote:
(I _think_ we should have the **`!x86_gcc2`** but I'm not sure.)
Yes, it means "tested on x86_gcc2, does not work".
|
|
OK, thanks. |
|
Now that this PR has been merged, the branch it is based on is no longer needed. |
R167 commentedNov 30, 2016
Added in gif2apng recipe. Does not support gcc2.