How to make WINE open an exe-file only by its name, but omitting the extension EXE?
How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Is possible to make WINE open an exe-file only by its name, but omitting the extension EXE?
I am running linux Manjaro, Xfce and I have application Simplicity Studio IDE from Silicon Labs, that uses WINE to build projects. It worked well in KDE, but after one crush I reinstalled clean the entire system and used Xfce instead of KDE. After that, WINE integration with the IDE stopped working with the error:
wine: failed to open “/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51”: c0000135
(the file is C51.EXE)
The Simplicity Studio IDE omits the extension EXE at the end and this is the cause of the error.
It didn’t cause this problem before in KDE, but now WINE can’t find the file without extension.
Is it possible to make WINE open an exe-file only by its name, but omitting the extension EXE?
Thank you.
I am running linux Manjaro, Xfce and I have application Simplicity Studio IDE from Silicon Labs, that uses WINE to build projects. It worked well in KDE, but after one crush I reinstalled clean the entire system and used Xfce instead of KDE. After that, WINE integration with the IDE stopped working with the error:
wine: failed to open “/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51”: c0000135
(the file is C51.EXE)
The Simplicity Studio IDE omits the extension EXE at the end and this is the cause of the error.
It didn’t cause this problem before in KDE, but now WINE can’t find the file without extension.
Is it possible to make WINE open an exe-file only by its name, but omitting the extension EXE?
Thank you.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
If I run the exe-file within the folder, then WINE opens the file with extension omitted, without problems.
On Manjaro forum I was very much helped and suggested the following:
As workaround you can set the WINEPATH:
env WINEPREFIX=$HOME/.wine WINEPATH=$HOME/Downloads wine "binary_file"
On Manjaro forum I was very much helped and suggested the following:
As workaround you can set the WINEPATH:
env WINEPREFIX=$HOME/.wine WINEPATH=$HOME/Downloads wine "binary_file"
-
- Level 5
- Posts: 359
- Joined: Tue Dec 24, 2019 3:23 pm
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Well one quick and dirty way to do it on a file-by-file basis is to go to the directory where the file is and create a symbolic link(a name of anything you want pointing to the actual file:
But there might be a more elegant/universal solution, just wanted to post this in case there isn't(I don't know).
Code: Select all
ln -s C51.EXE C51
Code: Select all
ls -l C51
lrwxrwxrwx 1 username username 7 Jun 8 14:16 C51 -> C51.EXE
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Thank you @invisible kid, but I need "more elegant/universal solution", something that I was suggested on Manjaro forum, to use WINEPATH variable, that I am yet to understand.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
I need to make wine run application only by its name without a exe-suffix.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Did you try setting up the symbolic link as Invisible Kid showed? you SHOULD be able to run the exe without the exe externsion now. C51, via the link, should act the same as if you had said C51.exe - you don't need the exe.
Try that in a terminal window and post back the results.
Try that in a terminal window and post back the results.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Yes it works with symbolic link. Interesting fact is that if I switch to the folder where exe-file is located, so that no need for the full path, then I can run it without extension, like that: WINE FILENAME, and it works. If I rename the file by removing the extension, then WINE finds the file. My problem is that SimplicityStudio IDE generates Makefiles wich have many lines where WINE runs a file with a full path, and in all those lines exe-files have no extension. So, creating symbolic link or switching to the folder will not solve my problem.
Thank you
Thank you
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
And at each of those paths if you create a link there for that given object what happens? If it's generating <complete path>x, what happens when you put the link in <complete path> of x to x.exe for each of the paths and else's as needed?
Are you saying it builds the else's and tries to have wine execute them immediately afterwards without the extension??
Are you saying it builds the else's and tries to have wine execute them immediately afterwards without the extension??
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
You might also have wanted to post that you already had a post in the simplicityStudio form and the reply given there. I suspect your problem isn't as simple as you think. Please provide a complete log file from running simplicity studio. Would Luke to see alk the lines it is generating and executing.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Thank you for your response.
This is the makefile IDE generates:
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Keil tools exit code 1 is warnings only, so don't treat as an error in make
RC := test $$? -lt 2
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include src/subdir.mk
-include subdir.mk
-include objects.mk
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: F36x_Blinky_4.omf
# Tool invocations
F36x_Blinky_4.omf: echo_path $(OBJS)
@echo 'Building target: $@'
@echo 'Invoking: Keil 8051 Linker'
wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/LX51" "@F36x_Blinky_4.lnp" || $(RC)
@echo 'Finished building target: $@'
# Change from all upper case to the expected case
@-mv "F36X_BLINKY_4.OMF.CRBUILD" "$@"
# Generate hex file: F36x_Blinky_4.hex
@wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/Ohx51" "F36x_Blinky_4.omf" "HEXFILE (F36x_Blinky_4.hex)" "H386" 2>&1 >/dev/null
# Other Targets
clean:
-$(RM) $(EXECUTABLES)$(OBJS) F36x_Blinky_4.omf
-@echo ' '
.PHONY: all clean dependents
-include ../makefile.targets
# echo the path
echo_path:
@echo PATH=$$PATH
@echo ' '
-----------------------------------------------------
These are the compilation/build/ results:
------------------------------------------------------
02:27:30 **** Build of configuration Keil 8051 vnull - Debug for project F36x_Blinky_4 ****
make all
PATH=/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN:/home/username/SimplicityStudio_v5/support/8051:/usr/bin:/home/username/SimplicityStudio_v5/support/common/build:/home/username/.local/bin:/usr/local/bin:/bin:/usr/local/sbin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/var/lib/snapd/snap/bin
Building file: ../src/F36x_Blinky.c
Invoking: Keil 8051 Compiler
wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51" "@src/F36x_Blinky.__i" || test $? -lt 2
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
make: *** [src/subdir.mk:21: src/F36x_Blinky.OBJ] Error 1
"make all" terminated with exit code 2. Build might be incomplete.
02:27:42 Build Failed. 1 errors, 0 warnings. (took 11s.701ms)
This is the makefile IDE generates:
################################################################################
# Automatically-generated file. Do not edit!
################################################################################
# Keil tools exit code 1 is warnings only, so don't treat as an error in make
RC := test $$? -lt 2
-include ../makefile.init
RM := rm -rf
# All of the sources participating in the build are defined here
-include sources.mk
-include src/subdir.mk
-include subdir.mk
-include objects.mk
-include ../makefile.defs
# Add inputs and outputs from these tool invocations to the build variables
# All Target
all: F36x_Blinky_4.omf
# Tool invocations
F36x_Blinky_4.omf: echo_path $(OBJS)
@echo 'Building target: $@'
@echo 'Invoking: Keil 8051 Linker'
wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/LX51" "@F36x_Blinky_4.lnp" || $(RC)
@echo 'Finished building target: $@'
# Change from all upper case to the expected case
@-mv "F36X_BLINKY_4.OMF.CRBUILD" "$@"
# Generate hex file: F36x_Blinky_4.hex
@wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/Ohx51" "F36x_Blinky_4.omf" "HEXFILE (F36x_Blinky_4.hex)" "H386" 2>&1 >/dev/null
# Other Targets
clean:
-$(RM) $(EXECUTABLES)$(OBJS) F36x_Blinky_4.omf
-@echo ' '
.PHONY: all clean dependents
-include ../makefile.targets
# echo the path
echo_path:
@echo PATH=$$PATH
@echo ' '
-----------------------------------------------------
These are the compilation/build/ results:
------------------------------------------------------
02:27:30 **** Build of configuration Keil 8051 vnull - Debug for project F36x_Blinky_4 ****
make all
PATH=/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN:/home/username/SimplicityStudio_v5/support/8051:/usr/bin:/home/username/SimplicityStudio_v5/support/common/build:/home/username/.local/bin:/usr/local/bin:/bin:/usr/local/sbin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/var/lib/snapd/snap/bin
Building file: ../src/F36x_Blinky.c
Invoking: Keil 8051 Compiler
wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51" "@src/F36x_Blinky.__i" || test $? -lt 2
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
make: *** [src/subdir.mk:21: src/F36x_Blinky.OBJ] Error 1
"make all" terminated with exit code 2. Build might be incomplete.
02:27:42 Build Failed. 1 errors, 0 warnings. (took 11s.701ms)
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
So I don't see anything that shows it building C51 so I have to assume it already existed. So, if you put the link in the /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN folder and then rerun the process you showed in your log what happens? I'm just an inexperienced person trying to help so I hope you don't mind if I ask a dumb question. Also, perhaps a list of the contents of
and perhaps
I'm curious as to what it is showing in that folder.
Code: Select all
ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51
Code: Select all
ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe
Code: Select all
ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Thank you for your help.
These are the results from console:
[... ~]$ cd /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN
[... BIN]$ ln -s C51.EXE C51
[... BIN]$ ls -l C51
lrwxrwxrwx 1 username username 7 Jun 10 03:30 C51 -> C51.EXE
[... BIN]$ wine C51
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights res
erved.
...... it worked well
[... BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
[... BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights res
erved.
...... it worked well
[... BIN]$ cd ~
[... ~]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
[..~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51': No such file or directory
[... ~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe': No such file or directory
[... ~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
[... ~]$ cd /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN
[... BIN]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
I am very grateful for your help.
These are the results from console:
[... ~]$ cd /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN
[... BIN]$ ln -s C51.EXE C51
[... BIN]$ ls -l C51
lrwxrwxrwx 1 username username 7 Jun 10 03:30 C51 -> C51.EXE
[... BIN]$ wine C51
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights res
erved.
...... it worked well
[... BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
[... BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights res
erved.
...... it worked well
[... BIN]$ cd ~
[... ~]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
wine: failed to open "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51": c0000135
[..~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51': No such file or directory
[... ~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe': No such file or directory
[... ~]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
[... ~]$ cd /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN
[... BIN]$ ls /home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
I am very grateful for your help.
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
I am sorry. Please, ignore the previous post.
I can't correct the previous post, but I didn't notice that that the link created was broken and in the rest of lines my real username was incorrect. I am very sorry.
Now it is correct:
[... BIN]$ ln -s C51.EXE C51
[....BIN]$ ls -l C51
lrwxrwxrwx 1 username username 7 Jun 10 08:18 C51 -> C51.exe
After that it works with the link:
[...BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights reserved.
[... ~]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights reserved.
Also, your commands:
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe"
/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE"
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
Thank you.
I can't correct the previous post, but I didn't notice that that the link created was broken and in the rest of lines my real username was incorrect. I am very sorry.
Now it is correct:
[... BIN]$ ln -s C51.EXE C51
[....BIN]$ ls -l C51
lrwxrwxrwx 1 username username 7 Jun 10 08:18 C51 -> C51.exe
After that it works with the link:
[...BIN]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights reserved.
[... ~]$ wine "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
C51 COMPILER V9.60.0.0 - SN: K1FPC-20EFSZ
COPYRIGHT Copyright (C) 2012 - 2019 ARM Ltd and ARM Germany GmbH. All rights reserved.
Also, your commands:
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51"
/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe"
/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.exe
[... ~]$ ls "/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE"
ls: cannot access '/home/username/SimplicityStudio_v5/developer/toolchains/keil_8051/9.60/BIN/C51.EXE': No such file or directory
Thank you.
-
- Level 5
- Posts: 359
- Joined: Tue Dec 24, 2019 3:23 pm
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
If you're compiling and such, could using something like Cygwin work/help?
https://www.cygwin.com/
As a matter of fact that is the first thing I thought of when the topic of extensions came up. Cygwin seems to have that all smoothed-over.
If not, good luck still!
https://www.cygwin.com/
As a matter of fact that is the first thing I thought of when the topic of extensions came up. Cygwin seems to have that all smoothed-over.
If not, good luck still!
Re: How to make WINE open an exe-file only by its name, but omitting the extension EXE?
Hi invisible kid,
I used your advice and created a bunch of links as you suggested and it works. I can actually use the IDE. It's not exactly what I wanted, but I can use it now, at least for the existing projects. I still want to find more elegant solution. I have to read carefully what Cygwin can do. Thank you.
Tank you very much
I used your advice and created a bunch of links as you suggested and it works. I can actually use the IDE. It's not exactly what I wanted, but I can use it now, at least for the existing projects. I still want to find more elegant solution. I have to read carefully what Cygwin can do. Thank you.
Tank you very much
-
- Level 5
- Posts: 359
- Joined: Tue Dec 24, 2019 3:23 pm