I want to migrate CVS repositories into Gitlab. I have multiple modules under a repository and few modules have multiple jars in it. I used the cvs2git tool to migrate this, it's migrated without any issues but I couldn't compile the repository after migration because few jars getting corrupted. Why it's getting corrupted?
While compilation the builds are failing, I just checked the jars which was getting corrupted,
jar -tvf ./<path>/<myjar>.jar
java.util.zip.ZipException: invalid END header (bad central directory offset)
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:219)
at java.util.zip.ZipFile.<init>(ZipFile.java:149)
at java.util.zip.ZipFile.<init>(ZipFile.java:120)
at sun.tools.jar.Main.list(Main.java:1115)
at sun.tools.jar.Main.run(Main.java:293)
at sun.tools.jar.Main.main(Main.java:1288)
My jars in CVS as well as in GIT after migration as follows,
GIT
[root@test myrepo]# ls -ltr ./<path>/isorelax-20030108.jar
-rwxr-xr-x 1 root root 192232 Sep 27 16:54 ./<path>/isorelax-20030108.jar
[root@test myrepo]# ls -ltr ./<path>/opt/isorelax-20030108.jar
-rw-r--r-- 1 root root 192232 Sep 27 16:54 ./<path>/opt/isorelax-20030108.jar
CVS
[root@test myrepo]# ls -ltr ./<path>/isorelax-20030108.jar
-rwxr-x--- 1 root root 192743 Jun 10 2015 ./<path>/isorelax-20030108.jar
[root@test myrepo]# ls -ltr ./<path>/opt/isorelax-20030108.jar
-rw-r----- 1 root root 192602 Jun 30 2015 ./<path>/opt/isorelax-20030108.jar
We are accessing ./opt/isorelax-20030108.jar jar while compiling but getting failed in GIT but CVS builds successfully.
I ran the CVS status on the jars one is showing with -kb but another one is not.
[root@test myrepo]# cvs status ./<path>/isorelax-20030108.jar
=============================================================
File: isorelax-20030108.jar Status: Up-to-date
Working revision: 1.2.1
Repository revision: 1.2.1 /cvs/myrepo/<path>/isorelax-20030108.jar,v
Sticky Tag: TAG_1 (revision: 1.2.1)
Sticky Date: (none)
Sticky Options: (none)
[root@test myrepo]# cvs status ./<path>/opt/isorelax-20030108.jar
=================================================================
File: isorelax-20030108.jar Status: Up-to-date
Working revision: 1.2.3
Repository revision: 1.2.3 /cvs/myrepo/<path>/opt/isorelax-20030108.jar,v
Sticky Tag: TAG_1 (revision: 1.2.3)
Sticky Date: (none)
Sticky Options: -kb
We are accessing the jars with Sticky Options: -kb, still it's failing...
What was the problem here? Kindly provide your thoughts on this.