Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
VirusCheckPlugin4Rosetta
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Digital Preservation
VirusCheckPlugin4Rosetta
Commits
4fc908f0
Commit
4fc908f0
authored
1 year ago
by
Jens Steidl
Browse files
Options
Downloads
Patches
Plain Diff
- refactor: updated & simplified for current SDKs
parent
e4341e3e
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Makefile
+14
-16
14 additions, 16 deletions
Makefile
with
14 additions
and
16 deletions
Makefile
+
14
−
16
View file @
4fc908f0
...
...
@@ -3,27 +3,25 @@
# von ExLibris an Rosetta übergibt.
# Pfad zu Java
JAVAPATH
=
$(
wildcard /usr/lib/jvm/java-1.17.0-openjdk-
*
/bin/
)
JAVARELEASE
=
17
JAVAPATH
:
=
$(
wildcard /usr/lib/jvm/java-1.17.0-openjdk-
*
/bin/
)
JAVARELEASE
:
=
17
# Verwendete Rosetta-Version
ROSETTAVERSION
:=
7.3
.0
ROSETTAVERSION
:=
8.0
.0
# Pfad zum Rosetta-SDK
ROSETTASDK
:=
$(
shell find /exlibris/
-type
d
-regex
".*dps-sdk-
${
ROSETTAVERSION
}
/lib
$$
"
)
# Pfad zum Rosetta-SDK, Deposit-Module
ROSETTASDKDEPOSIT
:=
${
ROSETTASDK
}
/../dps-sdk-projects/dps-sdk-deposit/lib
ROSETTASDKPLUGINS
:=
${
ROSETTASDK
}
/../../bundled_plugins/
ROSETTASDKJARS
=
$(
shell find
${
ROSETTASDKDEPOSIT
}
-name
"*.jar"
)
ROSETTASDK
:=
/exlibris/dps/d4_1/system.dir/dps-sdk-
${
ROSETTAVERSION
}
/dps-sdk-projects/dps-sdk-deposit/lib/
# classpath
JUNITCLASSPATH
:=
./java/:/usr/share/java/junit4.jar
:
$(
shell find
${
ROSETTASDKDEPOSIT
}
-name
"*.jar"
-print
|xargs
echo
|sed
-e
"s/ /:/g"
)
CLASSPATH
:=
$
{
ROSETTASDKDEPOSIT
}
/../src/:
${
ROSETTASDKDEPOSIT
}
/xmlbeans-2.3.0.jar:
${
ROSETTASDKDEPOSIT
}
/dps-sdk-
${
ROSETTAVERSION
}
.jar:
${
ROSETTASDKDEPOSIT
}
/log4j-1.2.14.jar:
${
ROSETTASDKPLUGINS
}
/NFSStoragePlugin.jar
JUNITCLASSPATH
:=
./java/:/usr/share/java/junit4.jar
CLASSPATH
:=
$
(
shell find
${
ROSETTASDK
}
-name
"*.jar"
-print
| xargs
echo
|
sed
-e
"s/ /:/g"
)
# sources
SOURCES
:=
java/org/slub/rosetta/dps/repository/plugin/SLUBVirusCheckClamAVPlugin.java
PLUGINCLASS
:=
SLUBVirusCheckClamAVPlugin
PLUGINCLASSPATH
:=
org.slub.rosetta.dps.repository.plugin.
${
PLUGINCLASS
}
SOURCES
:=
java/org/slub/rosetta/dps/repository/plugin/
${
PLUGINCLASS
}
.java
OBJS
:=
$(
SOURCES:.java
=
.class
)
JAR
:=
SLUBVirusCheckClamAVPlugin
.jar
JAR
:=
${
PLUGINCLASS
}
.jar
BUILD
:=
build/
SHELL
=
/bin/bash
...
...
@@ -44,8 +42,8 @@ clean: jarclean
@
rm
-Rf
doc/
@
find ./java/org/
-name
"*.class"
-exec
rm
-f
\{\}
\;
@
rm
-Rf
$(
JAR
)
@
rm
test_novirus
@
rm
test_eicar
@
rm
-Rf
test_novirus
@
rm
-Rf
test_eicar
distclean
:
clean
find ./
-name
"*~"
-exec
rm
-f
\{\}
\;
...
...
@@ -74,12 +72,12 @@ check_prerequisites:
test_eicar
:
$(OBJS)
@
/usr/bin/java
-cp
$(
CLASSPATH
)
:
$(
JUNITCLASSPATH
)
:java
org.slub.rosetta.dps.repository.plugin.SLUBVirusCheckClamAVPlugin
EICAR/eicar |
grep
-F
'SIGNATURE:'
>
$@
@
/usr/bin/java
-cp
$(
CLASSPATH
)
:
$(
JUNITCLASSPATH
)
:java
${
PLUGINCLASSPATH
}
EICAR/eicar |
grep
-F
'SIGNATURE:'
>
$@
@
echo
-n
"testing 'EICAR':"
@
if
[[
"
$$(
cat test_eicar
)
"
=
"RESULT: 2 SIGNATURE: Eicar-Signature"
]]
;
then
echo
pass
;
else
echo
failed
;
exit
2
;
fi
test_novirus
:
$(OBJS)
@
/usr/bin/java
-cp
$(
CLASSPATH
)
:
$(
JUNITCLASSPATH
)
:java
org.slub.rosetta.dps.repository.plugin.SLUBVirusCheckClamAVPlugin
Makefile |
grep
-F
'SIGNATURE:'
>
$@
@
/usr/bin/java
-cp
$(
CLASSPATH
)
:
$(
JUNITCLASSPATH
)
:java
${
PLUGINCLASSPATH
}
Makefile |
grep
-F
'SIGNATURE:'
>
$@
@
echo
-n
"testing 'No virus': "
@
if
[[
"
$$(
cat test_novirus
)
"
=
"RESULT: 0 SIGNATURE: "
]]
;
then
echo
pass
;
else
echo
fail
;
exit
2
;
fi
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment