Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creates corrupt .INSTALL script #89

Open
latekvo opened this issue Oct 11, 2023 · 1 comment
Open

Creates corrupt .INSTALL script #89

latekvo opened this issue Oct 11, 2023 · 1 comment

Comments

@latekvo
Copy link

latekvo commented Oct 11, 2023

I will follow up on this later but Im running late today and just wanted to report as much as i remember for today.
When i used debtap on Cisco packet tracer 8.2.1-1 debian package, the install script that had been generated was missing line 20 causing pacman to crash during the install with this error:

/tmp/alpm_qPMsyx/.INSTALL: line 20: syntax error near unexpected token `else'
/tmp/alpm_qPMsyx/.INSTALL: line 20: `	    else'
/usr/bin/bash: line 1: pre_upgrade: command not found
error: command failed to execute correctly

context:

pre_install() {
	STATE=1 
	while [ "$STATE" != 0 -a "$STATE" != 4 ]; do
	    case "$STATE" in
	    1)
	    ;;
	    2)
	    ;;
	    3)
	        if [ "$RET" = "false" ]; then
	            exit 1
	        fi
	    ;;
	    esac
            # here is the missing IF statement
	        STATE=$(($STATE + 1))
	    else
	        STATE=$(($STATE - 1))
	    fi
	done
	exit 0
}

I later determined the missing statement has to be

        if [ "$STATE" -eq 3 ]; then

Please ask me for any missing details.

@latekvo
Copy link
Author

latekvo commented Oct 11, 2023

Hello I wanted to follow up,
during the install, there was one more error in the .INSTALL script, but it didn't prevent packettracer from installing.

:: Processing package changes...
/tmp/alpm_6jAOKD/.INSTALL: line 128: syntax error near unexpected token `elif'
/tmp/alpm_6jAOKD/.INSTALL: line 128: `	elif [ ! -r $PROFILE ]; then'
(1/1) reinstalling packettracer                                                                                    [####################################################################] 100%
/tmp/alpm_BhgJf8/.INSTALL: line 128: syntax error near unexpected token `elif'
/tmp/alpm_BhgJf8/.INSTALL: line 128: `	elif [ ! -r $PROFILE ]; then'
gtk-update-icon-cache: No theme index file.

I confirm that after making the changes i made to the .INSTALL script, the program installs and runs as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant