Hello Sir,

Regarding to this matter where you give this step by step :

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Just installing the package above is not enough. What you need to do is to install the package _inside_ the chroot. The steps you need to take are (roughly, it may vary slightly depending on your environment):

- copy icpc-kotlinc_1.1.4-3~icpc_all.deb somewhere into your chroot
- enter the chroot: sudo chroot /chroot/domjudge (or whatever path you build it at)
- install the package there: dpkg -i /path/to/icpc-kotlinc_1.1.4-3~icpc_all.deb
- if dpkg complains about missing dependencies, run 'apt-get -f install' or install them and then try again
- exit the chroot and test if it works

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

It works well. Now Kotlin is work in our Domjudge. It think it should be added to installation manual at Domjudge page

Thanks for your guidance Sir, it is so helpful. :)


P.S. On second thought,  do you mind answer my latest mail question about re-run chroot, Sir ?


Regards,

Andrew Jauhari



On 1/14/2018 12:18 AM, Andrew Jauhari wrote:

I will try them tomorrow since I'm not at my office anymore, I will update you about this whether it works or not.

But lastly I want to ask about this,

Do re-running dj_make_chroot and dj_make_chroot_java for second times will affect the whole domjudge especially judgehost? I asked this because when I suspect about kotlin is not included in chroot enviroment, i tried to re-run them. The judgehost itself seems works after that. But I dont know the impact it will create. Can you give confirmation and more information about this ?

And if it has impact to domjudge, please tell me too if I need to reconfigure the whole judgehost from the scratch.

Thanks again, Sir


Regards
Andrew Jauhari

Sent from my ASUS


-------- Original Message --------
From:Jaap Eldering
Sent:Sat, 13 Jan 2018 23:51:23 +0700
To:DOMjudge-devel mailinglist
Subject:Re: Kotlin Problem

Hi Andrew,

[Also including the list again, I made the mistake of dropping it in my first reply.]

On 13/01/18 17:30, Andrew Jauhari wrote:
> Thanks for the quick reply again, Sir.
>
> I was supiscious about kotlin is not installed in chroot enviroment too but i have no idea how to install them at chroot enviroment.
>
> Before you reply, I have managed to make kotlin work by compiling using kotlinc to make java executable (jar), and finally running the program using java and -jar parameter on addition other java parameter. But I worry that it will create future unknown problem.
>
> Anyway , I need more guidance to install kotlin at chroot mode. Do installing from https://www.domjudge.org/icpc-kotlinc_1.1.4-3~icpc_all.deb, will install kotlin to the chroot environment? Do I need any more steps to make it available to chroot enviroment?

Just installing the package above is not enough. What you need to do is to install the package _inside_ the chroot. The steps you need to take are (roughly, it may vary slightly depending on your environment):

- copy icpc-kotlinc_1.1.4-3~icpc_all.deb somewhere into your chroot
- enter the chroot: sudo chroot /chroot/domjudge (or whatever path you build it at)
- install the package there: dpkg -i /path/to/icpc-kotlinc_1.1.4-3~icpc_all.deb
- if dpkg complains about missing dependencies, run 'apt-get -f install' or install them and then try again
- exit the chroot and test if it works

You might need to bind mount /proc, /dev, and/or /dev/pts inside the chroot to make apt-get work. See the domjudge chroot-start-stop.sh file for examples how to do so.

Best,
Jaap


> Thanks before for your guidance.
>
> Regards
> Andrew Jauhari
>
>
>
>
> Sent from my ASUS
>
> -------- Original Message --------
> From:Jaap Eldering
> Sent:Sat, 13 Jan 2018 20:24:05 +0700
> To:Andrew Jauhari
> Subject:Re: Kotlin Problem
>
> Hi Andrew,
>
> On 13/01/18 11:17, Andrew Jauhari wrote:
>> Dear Domjudge - Developers,
>>
>> Hello again, I have problem to integrate Kotlin compiler in judgehost. For information, I'm using ubuntu 16.04 and I was installing kotlin from sdkman. But when compiling, it seems that domjudge cannot find kotlinc and kotlin. I have try to move kotlinc and kotlin to /bin/ directory. It seems to solve kotlinc problem, but domjudge still cannot execute kotlin.
>>
>>
>>
>> When I try to go to directory where /testcase001/execdir/program resides, and then execute it myself. It seems work and no problem.
>> Trying to re-chroot seems doesn't fix this too.
>
> Did you also install kotlin inside the chroot? Compilation is done outside the chroot, so you need kotlinc available there, but the program is executed inside, so you need kotlin and the Kotlin support libraries inside there.
>
> If you want you can download https://www.domjudge.org/icpc-kotlinc_1.1.4-3~icpc_all.deb and install that. It's the Kotlin package used for the 2018 world finals environment, and we've also used it during NWERC 2017.
>
> Best,
> Jaap
>
>
>> Looking forward for your replay. Thanks before
>>
>>
>> Regards,
>> Andrew Jauhari
>>
>>
>> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>> Avast logo
>>
>> This email has been checked for viruses by Avast antivirus software.
>> www.avast.com
>>
>>
>> <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>
>>
>>
>> _______________________________________________
>> DOMjudge-devel mailing list
>> DOMjudge-devel@domjudge.org
>> https://www.domjudge.org/mailman/listinfo/domjudge-devel
>>
>

_______________________________________________
DOMjudge-devel mailing list
DOMjudge-devel@domjudge.org
https://www.domjudge.org/mailman/listinfo/domjudge-devel


_______________________________________________
DOMjudge-devel mailing list
DOMjudge-devel@domjudge.org
https://www.domjudge.org/mailman/listinfo/domjudge-devel