diff --git a/app-arch/unrar/patches/unrar-4.2.4.patch b/app-arch/unrar/patches/unrar-4.2.4.patchset similarity index 67% rename from app-arch/unrar/patches/unrar-4.2.4.patch rename to app-arch/unrar/patches/unrar-4.2.4.patchset index bd12da35b..f2e6779cf 100644 --- a/app-arch/unrar/patches/unrar-4.2.4.patch +++ b/app-arch/unrar/patches/unrar-4.2.4.patchset @@ -1,7 +1,14 @@ -diff -aur unrar/arcread.cpp unrar.4.2.4.haiku/arcread.cpp ---- unrar/arcread.cpp 2012-06-09 15:21:04.066584576 +0200 -+++ unrar.4.2.4.haiku/arcread.cpp 2013-01-17 21:57:19.749207552 +0100 -@@ -666,7 +666,7 @@ +From 8f6a22fb6cb4dcaf80049a7c82973251ffd07f80 Mon Sep 17 00:00:00 2001 +From: Adrien Destugues +Date: Wed, 2 Oct 2013 18:45:05 +0200 +Subject: Convert existing patch to patchset format. + + +diff --git a/arcread.cpp b/arcread.cpp +index a524a96..19cca29 100644 +--- a/arcread.cpp ++++ b/arcread.cpp +@@ -666,7 +666,7 @@ void Archive::ConvertUnknownHeader() { if (*s=='/' || *s=='\\') *s=CPATHDIVIDER; @@ -10,10 +17,11 @@ diff -aur unrar/arcread.cpp unrar.4.2.4.haiku/arcread.cpp if ((byte)*s<32 || (byte)*s>127) *s='_'; #endif -diff -aur unrar/consio.cpp unrar.4.2.4.haiku/consio.cpp ---- unrar/consio.cpp 2012-06-09 15:21:04.000524288 +0200 -+++ unrar.4.2.4.haiku/consio.cpp 2013-01-21 22:23:37.662437888 +0100 -@@ -141,7 +141,7 @@ +diff --git a/consio.cpp b/consio.cpp +index 42b72a6..90d22c9 100644 +--- a/consio.cpp ++++ b/consio.cpp +@@ -141,7 +141,7 @@ void GetPasswordText(wchar *Str,uint MaxLength) SetConsoleMode(hConOut,ConOutMode); #else char StrA[MAXPASSWORD]; @@ -22,10 +30,11 @@ diff -aur unrar/consio.cpp unrar.4.2.4.haiku/consio.cpp fgets(StrA,ASIZE(StrA)-1,stdin); #else strncpyz(StrA,getpass(""),ASIZE(StrA)); -diff -aur unrar/extract.cpp unrar.4.2.4.haiku/extract.cpp ---- unrar/extract.cpp 2012-06-09 15:21:04.002097152 +0200 -+++ unrar.4.2.4.haiku/extract.cpp 2013-01-17 21:42:21.914620416 +0100 -@@ -311,7 +311,7 @@ +diff --git a/extract.cpp b/extract.cpp +index ddd71a0..adccadf 100644 +--- a/extract.cpp ++++ b/extract.cpp +@@ -311,7 +311,7 @@ bool CmdExtract::ExtractCurrentFile(CommandData *Cmd,Archive &Arc,size_t HeaderS bool WideName=false; #endif @@ -34,10 +43,11 @@ diff -aur unrar/extract.cpp unrar.4.2.4.haiku/extract.cpp if (WideName) { // Prepare UTF-8 name for OS X. Since we are sure that destination -diff -aur unrar/file.cpp unrar.4.2.4.haiku/file.cpp ---- unrar/file.cpp 2012-06-09 15:21:04.002621440 +0200 -+++ unrar.4.2.4.haiku/file.cpp 2013-01-21 22:12:02.543162368 +0100 -@@ -304,6 +304,8 @@ +diff --git a/file.cpp b/file.cpp +index dcf4e61..7a26155 100644 +--- a/file.cpp ++++ b/file.cpp +@@ -304,6 +304,8 @@ void File::Write(const void *Data,size_t Size) hFile=stderr; #endif break; @@ -46,10 +56,11 @@ diff -aur unrar/file.cpp unrar.4.2.4.haiku/file.cpp } #endif while (1) -diff -aur unrar/find.cpp unrar.4.2.4.haiku/find.cpp ---- unrar/find.cpp 2012-06-09 15:21:04.003145728 +0200 -+++ unrar.4.2.4.haiku/find.cpp 2013-01-17 21:43:25.860618752 +0100 -@@ -104,7 +104,7 @@ +diff --git a/find.cpp b/find.cpp +index 7ba14c0..0f7c3c0 100644 +--- a/find.cpp ++++ b/find.cpp +@@ -104,7 +104,7 @@ bool FindFile::Next(struct FindData *fd,bool GetSymLink) } } *fd->NameW=0; @@ -58,7 +69,7 @@ diff -aur unrar/find.cpp unrar.4.2.4.haiku/find.cpp if (!LowAscii(fd->Name)) UtfToWide(fd->Name,fd->NameW,sizeof(fd->NameW)); #elif defined(UNICODE_SUPPORTED) -@@ -170,7 +170,7 @@ +@@ -170,7 +170,7 @@ bool FindFile::FastFind(const char *FindMask,const wchar *FindMaskW,FindData *fd strcpy(fd->Name,FindMask); *fd->NameW=0; @@ -67,10 +78,11 @@ diff -aur unrar/find.cpp unrar.4.2.4.haiku/find.cpp if (!LowAscii(fd->Name)) UtfToWide(fd->Name,fd->NameW,sizeof(fd->NameW)); #elif defined(UNICODE_SUPPORTED) -diff -aur unrar/makefile.unix unrar.4.2.4.haiku/makefile.unix ---- unrar/makefile.unix 2012-05-15 07:31:03.004980736 +0200 -+++ unrar.4.2.4.haiku/makefile.unix 2013-01-21 22:17:15.800325632 +0100 -@@ -7,7 +7,11 @@ +diff --git a/makefile.unix b/makefile.unix +index bd06092..b5e3815 100644 +--- a/makefile.unix ++++ b/makefile.unix +@@ -7,7 +7,11 @@ CXXFLAGS=-O2 LIBFLAGS=-fPIC DEFINES=-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE STRIP=strip @@ -83,7 +95,7 @@ diff -aur unrar/makefile.unix unrar.4.2.4.haiku/makefile.unix # Linux using LCC #CXX=lcc -@@ -114,12 +118,14 @@ +@@ -114,12 +118,14 @@ install: install-unrar uninstall: uninstall-unrar clean: @@ -100,7 +112,7 @@ diff -aur unrar/makefile.unix unrar.4.2.4.haiku/makefile.unix sfx: WHAT=SFX_MODULE sfx: clean $(OBJECTS) -@@ -144,3 +150,29 @@ +@@ -144,3 +150,29 @@ install-lib: uninstall-lib: rm -f $(DESTDIR)/lib/libunrar.so @@ -130,9 +142,10 @@ diff -aur unrar/makefile.unix unrar.4.2.4.haiku/makefile.unix + echo "URL: http://www.rarlab.com/" >> $(DESCRIPTION) + cd dist && zip -9 -r -z -y $(PACKAGE_NAME).zip common $(COMMENT) < $(COMMENT) + -diff -aur unrar/os.hpp unrar.4.2.4.haiku/os.hpp ---- unrar/os.hpp 2012-06-09 15:21:04.005767168 +0200 -+++ unrar.4.2.4.haiku/os.hpp 2013-01-21 22:25:04.170655744 +0100 +diff --git a/os.hpp b/os.hpp +index 21488a8..ae2d0be 100644 +--- a/os.hpp ++++ b/os.hpp @@ -134,8 +134,9 @@ #define NM 1024 @@ -162,9 +175,10 @@ diff -aur unrar/os.hpp unrar.4.2.4.haiku/os.hpp #if defined(__sparc) || defined(sparc) || defined(__hpux) #ifndef BIG_ENDIAN #define BIG_ENDIAN -diff -aur unrar/raros.hpp unrar.4.2.4.haiku/raros.hpp ---- unrar/raros.hpp 2012-06-09 15:21:04.006553600 +0200 -+++ unrar.4.2.4.haiku/raros.hpp 2013-01-16 19:50:06.066060288 +0100 +diff --git a/raros.hpp b/raros.hpp +index ce853bd..b63d0f0 100644 +--- a/raros.hpp ++++ b/raros.hpp @@ -29,7 +29,7 @@ #endif #endif @@ -174,10 +188,11 @@ diff -aur unrar/raros.hpp unrar.4.2.4.haiku/raros.hpp #define _UNIX #define _BEOS #endif -diff -aur unrar/rartypes.hpp unrar.4.2.4.haiku/rartypes.hpp ---- unrar/rartypes.hpp 2012-06-09 15:21:04.006815744 +0200 -+++ unrar.4.2.4.haiku/rartypes.hpp 2013-01-19 23:12:46.715653120 +0100 -@@ -7,6 +7,7 @@ +diff --git a/rartypes.hpp b/rartypes.hpp +index a2d8b44..d8249b1 100644 +--- a/rartypes.hpp ++++ b/rartypes.hpp +@@ -7,6 +7,7 @@ typedef unsigned int uint; // 32 bits or more #define PRESENT_INT32 // undefine if signed 32 bits is not available @@ -185,7 +200,7 @@ diff -aur unrar/rartypes.hpp unrar.4.2.4.haiku/rartypes.hpp typedef unsigned int uint32; // 32 bits exactly typedef signed int int32; // signed 32 bits exactly -@@ -20,6 +21,7 @@ +@@ -20,6 +21,7 @@ typedef signed __int64 int64; // signed 64 bits typedef unsigned long long uint64; // unsigned 64 bits typedef signed long long int64; // signed 64 bits #endif @@ -193,10 +208,11 @@ diff -aur unrar/rartypes.hpp unrar.4.2.4.haiku/rartypes.hpp #if defined(_WIN_ALL) || defined(__GNUC__) || defined(__sgi) || defined(_AIX) || defined(__sun) || defined(__hpux) || defined(_OSF_SOURCE) -diff -aur unrar/rarvm.cpp unrar.4.2.4.haiku/rarvm.cpp ---- unrar/rarvm.cpp 2012-06-09 15:21:04.007077888 +0200 -+++ unrar.4.2.4.haiku/rarvm.cpp 2013-01-21 22:12:02.605814784 +0100 -@@ -792,6 +792,8 @@ +diff --git a/rarvm.cpp b/rarvm.cpp +index 8b85800..1f06581 100644 +--- a/rarvm.cpp ++++ b/rarvm.cpp +@@ -792,6 +792,8 @@ void RarVM::Optimize(VM_PreparedProgram *Prg) case VM_CMP: Cmd->OpCode=Cmd->ByteMode ? VM_CMPB:VM_CMPD; continue; @@ -205,7 +221,7 @@ diff -aur unrar/rarvm.cpp unrar.4.2.4.haiku/rarvm.cpp } if ((VM_CmdFlags[Cmd->OpCode] & VMCF_CHFLAGS)==0) continue; -@@ -835,6 +837,8 @@ +@@ -835,6 +837,8 @@ void RarVM::Optimize(VM_PreparedProgram *Prg) case VM_NEG: Cmd->OpCode=Cmd->ByteMode ? VM_NEGB:VM_NEGD; continue; @@ -214,7 +230,7 @@ diff -aur unrar/rarvm.cpp unrar.4.2.4.haiku/rarvm.cpp } } } -@@ -1102,6 +1106,8 @@ +@@ -1102,6 +1106,8 @@ void RarVM::ExecuteStandardFilter(VM_StandardFilters FilterType) SET_VALUE(false,&Mem[VM_GLOBALMEMADDR+0x20],DataSize); } break; @@ -223,10 +239,11 @@ diff -aur unrar/rarvm.cpp unrar.4.2.4.haiku/rarvm.cpp } } -diff -aur unrar/unicode.cpp unrar.4.2.4.haiku/unicode.cpp ---- unrar/unicode.cpp 2012-06-09 15:21:04.010747904 +0200 -+++ unrar.4.2.4.haiku/unicode.cpp 2013-01-17 21:41:15.856686592 +0100 -@@ -13,7 +13,7 @@ +diff --git a/unicode.cpp b/unicode.cpp +index a3022d2..3e29127 100644 +--- a/unicode.cpp ++++ b/unicode.cpp +@@ -13,7 +13,7 @@ bool WideToChar(const wchar *Src,char *Dest,size_t DestSize) if (WideCharToMultiByte(CP_ACP,0,Src,-1,Dest,(int)DestSize,NULL,NULL)==0) RetCode=false; @@ -235,7 +252,7 @@ diff -aur unrar/unicode.cpp unrar.4.2.4.haiku/unicode.cpp WideToUtf(Src,Dest,DestSize); #elif defined(MBFUNCTIONS) -@@ -73,7 +73,7 @@ +@@ -73,7 +73,7 @@ bool CharToWide(const char *Src,wchar *Dest,size_t DestSize) if (MultiByteToWideChar(CP_ACP,0,Src,-1,Dest,(int)DestSize)==0) RetCode=false; @@ -244,9 +261,11 @@ diff -aur unrar/unicode.cpp unrar.4.2.4.haiku/unicode.cpp UtfToWide(Src,Dest,DestSize); #elif defined(MBFUNCTIONS) -diff -aur unrar/unrar.rdef unrar.4.2.4.haiku/unrar.rdef ---- unrar/unrar.rdef 1970-01-01 01:00:00.000000000 +0100 -+++ unrar.4.2.4.haiku/unrar.rdef 2013-01-16 20:43:32.898629632 +0100 +diff --git a/unrar.rdef b/unrar.rdef +new file mode 100644 +index 0000000..ab085d2 +--- /dev/null ++++ b/unrar.rdef @@ -0,0 +1,13 @@ + +resource app_signature "application/x-vnd.Roshal-UnRAR"; @@ -261,3 +280,6 @@ diff -aur unrar/unrar.rdef unrar.4.2.4.haiku/unrar.rdef + short_info = "4.2.4", + long_info = "4.2.4 Alexander Roshal" +}; +-- +1.8.3.4 + diff --git a/app-arch/unrar/unrar-4.2.4.recipe b/app-arch/unrar/unrar-4.2.4.recipe index 0fecb8745..661ff0454 100644 --- a/app-arch/unrar/unrar-4.2.4.recipe +++ b/app-arch/unrar/unrar-4.2.4.recipe @@ -1,21 +1,34 @@ -DESCRIPTION="unrar" +SUMMARY="Uncompress rar files" HOMEPAGE="http://www.rarlab.com/" SRC_URI="http://www.rarlab.com/rar/unrarsrc-4.2.4.tar.gz" REVISION="1" -STATUS_HAIKU="stable" -DEPEND="" +ARCHITECTURES="x86_gcc2 x86" CHECKSUM_MD5="8ea9d1b4139474b282d76e627a2de3e4" + +PROVIDES=" + unrar = $portVersion + cmd:unrar = $portVersion + " + +REQUIRES=" + haiku >= $haikuVersion + " +BUILD_REQUIRES=" + cmd:make + cmd:g++ + " + +SOURCE_DIR="unrar" BUILD() { - cd unrar - make -f makefile.unix DESTDIR=`finddir B_COMMON_DIRECTORY` + LDFLAGS=-lbsd make -f makefile.unix DESTDIR=$prefix } INSTALL() { - cd unrar - make -f makefile.unix DESTDIR=`finddir B_COMMON_DIRECTORY` install + make -f makefile.unix DESTDIR=$prefix install } LICENSE="UnRAR" COPYRIGHT="Alexander Roshal" +DESCRIPTION="Uncompress rar files"