areca: init at 7.5
This commit is contained in:
parent
b0124eb099
commit
6f0a651c7e
49
pkgs/applications/backup/areca/default.nix
Normal file
49
pkgs/applications/backup/areca/default.nix
Normal file
@ -0,0 +1,49 @@
|
||||
{ stdenv, fetchurl, ant, jre, jdk, swt, acl, attr }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "areca-7.5";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://downloads.sourceforge.net/project/areca/areca-stable/areca-7.5/areca-7.5-src.tar.gz";
|
||||
sha256 = "1q4ha9s96c1syplxm04bh1v1gvjq16l4pa8w25w95d2ywwvyq1xb";
|
||||
};
|
||||
|
||||
sourceRoot = ".";
|
||||
|
||||
buildInputs = [ jdk ant acl attr ];
|
||||
|
||||
patches = [ ./fix-javah-bug.diff ];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace build.xml --replace "/usr/lib/java/swt.jar" "${swt}/jars/swt.jar"
|
||||
substituteInPlace build.xml --replace "gcc" "${stdenv.cc}/bin/gcc"
|
||||
substituteInPlace areca.sh --replace "bin/" ""
|
||||
substituteInPlace bin/areca_run.sh --replace "/usr/java" "${jre}/lib/openjdk"
|
||||
substituteInPlace bin/areca_run.sh --replace "/usr/lib/java/swt.jar" "${swt}/jars/swt.jar"
|
||||
|
||||
sed -i "s#^PROGRAM_DIR.*#PROGRAM_DIR=$out#g" bin/areca_run.sh
|
||||
sed -i "s#^LIBRARY_PATH.*#LIBRARY_PATH=${swt}/lib:$out/lib:${acl}/lib#g" bin/areca_run.sh
|
||||
|
||||
# https://sourceforge.net/p/areca/bugs/563/
|
||||
substituteInPlace bin/areca_run.sh --replace '[ "$JAVA_IMPL" = "java" ]' \
|
||||
'[[ "$JAVA_IMPL" = "java" || "$JAVA_IMPL" = "openjdk" ]]'
|
||||
'';
|
||||
|
||||
buildPhase = "ant";
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin $out/lib $out/translations
|
||||
cp areca.sh $out/bin/areca
|
||||
cp -r bin $out
|
||||
cp -r lib $out
|
||||
cp -r translations $out
|
||||
cp COPYING $out
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = http://www.areca-backup.org/;
|
||||
description = "An Open Source personal backup solution";
|
||||
license = licenses.gpl2;
|
||||
maintainers = with maintainers; [ pSub ];
|
||||
};
|
||||
}
|
24
pkgs/applications/backup/areca/fix-javah-bug.diff
Normal file
24
pkgs/applications/backup/areca/fix-javah-bug.diff
Normal file
@ -0,0 +1,24 @@
|
||||
diff --git a/build.xml b/build.xml
|
||||
index 1ba08e0..9248b76 100644
|
||||
--- a/build.xml
|
||||
+++ b/build.xml
|
||||
@@ -56,10 +56,16 @@
|
||||
|
||||
<target name="compilejni" unless="isWindows">
|
||||
<description>JNI compilation task (builds libarecafs.so ... for unix-like operating systems only)</description>
|
||||
+
|
||||
<!--Generate the JNI header-->
|
||||
- <javah destdir="${root}/jni" force="yes" classpath="${root}/lib/areca.jar">
|
||||
- <class name="com.myJava.file.metadata.posix.jni.wrapper.FileAccessWrapper"/>
|
||||
- </javah>
|
||||
+ <exec executable="javah">
|
||||
+ <arg value="-d"/>
|
||||
+ <arg value="${root}/jni"/>
|
||||
+ <arg value="-force"/>
|
||||
+ <arg value="-classpath"/>
|
||||
+ <arg value="${root}/lib/areca.jar"/>
|
||||
+ <arg value="com.myJava.file.metadata.posix.jni.wrapper.FileAccessWrapper"/>
|
||||
+ </exec>
|
||||
|
||||
<!-- Compile the JNI code -->
|
||||
<exec dir="${root}/jni" executable="gcc">
|
@ -16035,6 +16035,8 @@ in
|
||||
|
||||
auctex = callPackage ../tools/typesetting/tex/auctex { };
|
||||
|
||||
areca = callPackage ../applications/backup/areca { };
|
||||
|
||||
beep = callPackage ../misc/beep { };
|
||||
|
||||
brgenml1lpr = callPackage_i686 ../misc/cups/drivers/brgenml1lpr {};
|
||||
|
Loading…
Reference in New Issue
Block a user