haiku-apps/BSAP: new recipe (#3335)

This commit is contained in:
Bach Nguyen
2018-11-05 16:37:22 -06:00
committed by fbrosson
parent f1c9ef6bc0
commit 9208ed3410
2 changed files with 70 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
SUMMARY="A desktop app to use various dictionaries"
DESCRIPTION="BSAP is an English-Polish, Polish-English dictionary program that \
uses dictionary data files from sap. It can also read dictionary data from \
Collins dictionary released by YDP."
HOMEPAGE="https://github.com/ytmytm/beos-bsap"
COPYRIGHT="2004-2018 Maciej Witkowiak"
LICENSE="GNU GPL v2"
REVISION="1"
srcGitRev="0f04a2464778fc2c92e11a5cbe481c037ccd7c2e"
SOURCE_URI="https://github.com/ytmytm/beos-bsap/archive/$srcGitRev.tar.gz"
CHECKSUM_SHA256="3e741f06495244327d137c9ad1fec2b2304029f2aa832fe08d58078c59fea6f8"
SOURCE_FILENAME="beos-bsap-$portVersion-$srcGitRev.tar.gz"
SOURCE_DIR="beos-bsap-$srcGitRev"
PATCHES="bsap-$portVersion.patchset"
ARCHITECTURES="!x86_gcc2 x86 x86_64"
if [ "$targetArchitecture" = x86_gcc2 ]; then
SECONDARY_ARCHITECTURES="x86"
fi
PROVIDES="
bsap$secondaryArchSuffix = $portVersion
app:BSAP = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
"
BUILD_PREREQUIRES="
makefile_engine
cmd:g++$secondaryArchSuffix
cmd:make
"
BUILD()
{
make OBJ_DIR=objects
}
INSTALL()
{
mkdir -p $appsDir
cp objects/BSAP $appsDir
addAppDeskbarSymlink $appsDir/BSAP
}

View File

@@ -0,0 +1,22 @@
From d2b519a6670efe98bfc9942be184600aafce52a3 Mon Sep 17 00:00:00 2001
From: Bach Nguyen <bach5000@gmail.com>
Date: Sat, 3 Nov 2018 20:45:54 +0000
Subject: Change variable type
diff --git a/bydpmainwindow.cpp b/bydpmainwindow.cpp
index 51d67cc..8d7715f 100644
--- a/bydpmainwindow.cpp
+++ b/bydpmainwindow.cpp
@@ -250,7 +250,7 @@ void BYdpMainWindow::NewClipData(void) {
if (be_clipboard->Lock()) {
if ((clip = be_clipboard->Data()))
- clip->FindData("text/plain", B_MIME_TYPE,(const void **)&text, &textLen);
+ clip->FindData("text/plain", B_MIME_TYPE,(const void **)&text, (ssize_t *)&textLen);
be_clipboard->Unlock();
result = "";
for (i=0;i<textLen;i++) {
--
2.19.0