Hello, I recently ran a sudo sh -c "echo 'foreign architecture i386' > 'etc//dpkg/dpkg.cfg.d/pkg-config-hook-config" command in an attempt to install steam on a amd64 architecture platform. However due to recent studies its seems it wasn't necessary to do that because 32-bit processing is already available in 64-bit architecture. The only reason I did it originally was because all the package manager could find was steam-devices. Yes, I am a total newb. Now, I'm trying to fix the configuration file and I don't know how to do that. I'll keep looking though. All in all its a Dpkg configuration error.
dpkg: error: configuration error: /etc/dpkg/dpkg.cfg.d/pkg-config-hook-config:1: unknown option '(it now states "amd64" in random unknowing attempts) E: Sub-process /usr/bin/dpkg returned an error code (2)
Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
Broken Pkg-Config-Hook-Config File
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 132 times
Re: Broken Pkg-Config-Hook-Config File
Here are the original file contents:
If you ever do something this stupid again and are stuck without an internet connection then check /var/cache/apt/archives/ for a copy of the dpkg .deb file and use this to unpack it so you can restore any files:
Code: Select all
post-invoke=if { test "$DPKG_HOOK_ACTION" = add-architecture || test "$DPKG_HOOK_ACTION" = remove-architecture; } && test -x /usr/share/pkg-config-dpkghook; then /usr/share/pkg-config-dpkghook update; fi
Code: Select all
ar x dpkg*.deb
tar xf data.tar.xz
deadbang
Re: Broken Pkg-Config-Hook-Config File
Thank you, you are my hero, it's my dream to be able to handle the system as well as you. However using this command
post-invoke=if { test "$DPKG_HOOK_ACTION" = add-architecture || test "$DPKG_HOOK_ACTION" = remove-architecture; } && test -x /usr/share/pkg-config-dpkghook; then /usr/share/pkg-config-dpkghook update; fi
I recieved and error message.
bash: syntax error near unexpected token `}'
Which is referring to the '}' located before && and after ;
I don't know how to correct that error. Also, thank you for the information about possible future errors, I've downloaded the post so I'll have it if needed.
post-invoke=if { test "$DPKG_HOOK_ACTION" = add-architecture || test "$DPKG_HOOK_ACTION" = remove-architecture; } && test -x /usr/share/pkg-config-dpkghook; then /usr/share/pkg-config-dpkghook update; fi
I recieved and error message.
bash: syntax error near unexpected token `}'
Which is referring to the '}' located before && and after ;
I don't know how to correct that error. Also, thank you for the information about possible future errors, I've downloaded the post so I'll have it if needed.
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 132 times
Re: Broken Pkg-Config-Hook-Config File
It's not a command, I posted the full content of /etc/dpkg/dpkg.cfg.d/pkg-config-hook-config for you to copy over.CoolDude2 wrote:using this command
Use this command to achieve that:
Code: Select all
sudo tee /etc/dpkg/dpkg.cfg.d/pkg-config-hook-config <<<'post-invoke=if { test "$DPKG_HOOK_ACTION" = add-architecture || test "$DPKG_HOOK_ACTION" = remove-architecture; } && test -x /usr/share/pkg-config-dpkghook; then /usr/share/pkg-config-dpkghook update; fi'
deadbang