LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Installing HLA - $PATH in Ubuntu (https://www.linuxquestions.org/questions/linux-software-2/installing-hla-%24path-in-ubuntu-4175653687/)

goldennuggets 05-10-2019 03:03 PM

Installing HLA - $PATH in Ubuntu
 
I'd like to start messing around with HLA a little, so I downloaded the files and was following the introductory information on this website:
http://www.plantation-productions.co...elloWorld.html

It mentions placing HLA in the path and exporting other variables.
There is no PATH variable in my .bashrc file. So, after some research I found that this is most likely in my .profile file. I updated it to include /usr/hla/ as explained in the above document.

This had no effect, even after issuing
Code:

source .profile
I'm at a loss as to what to try next and how to update the PATH variable as well as exporting the others to make this work properly. Currently using 64bit Kubuntu 19.04.

I'd appreciate any insight or help you can provide. Thanks!

scasey 05-10-2019 03:35 PM

One way:
In your .bashrc file put a line like
Code:

export PATH="/usr/hla:$PATH"
or, if you want it last instead of first
Code:

export PATH="$PATH:/usr/hla"
then source .bashrc or
Code:

. .bashrc
Entries in PATH don't typically end with a /, so /usr/hla rather than /usr/hla/ -- double-check your documentation about that.

You can also do this in .bash_profile (not .profile), but as I understand it, doing so in .bashrc insures every instance of the shell has the update PATH.

goldennuggets 05-10-2019 05:35 PM

Thank you that was perfect!



This is an aside, but once the above worked, the file could not be linked because I'm on a 64 bit and ld is trying to link as 32bit.

I found this resource: http://www.masmforum.com/board/index...c=17138.0;wap2

It's mistyped in the solution, so here is the correct solution.
If you're using HLA and you want link on 64bit, you need to pass a parameter to ld.
The way to do this is to include the -l option when compiling.

Code:

hla -lmelf_i386 -v hw


All times are GMT -5. The time now is 06:20 AM.