You are not logged in.

#1 2017-02-20 17:28:18

bltsrc
Member
Registered: 2017-02-20
Posts: 5

How to cope with syntax error in vanilla pkgbuild.sh?

Hi.
I recently Installed Arch Linux and found that my wireless card doesn't work.

Here's "what lspci -vnn -d 14e4:" gave me:

02:00.0 Network controller [0280]: Broadcom Limited BCM43142 802.11b/g/n [14e4:4365] (rev 01)
    Subsystem: Dell Wireless 1704 802.11n + BT 4.0 [1028:0016]
    Flags: bus master, fast devsel, latency 0, IRQ 17
    Memory at c0500000 (64-bit, non-prefetchable) [size=32K]
    Capabilities: <access denied>
    Kernel driver in use: bcma-pci-bridge
    Kernel modules: bcma

I read https://wiki.archlinux.org/index.php/Broadcom_wireless
and https://wiki.archlinux.org/index.php/Ar … g_packages carefully.

Ok, I upgraded my system via "pacman -Syu",
then downloaded broadcom-wl-dkms via git,
then issued "makepkg -si" in newly downloaded directory.

And I got:
/usr/share/makepkg/util/pkgbuild.sh: line 90: syntax error near unexpected token `<'
/usr/share/makepkg/util/pkgbuild.sh: line 90: `    done < <(grep_function "$funcname" "$attr_regex")'

What is in /usr/share/makepkg/util/pkgbuild.sh on 90th line:
done < <(grep_function "$funcname" "$attr_regex")

I have moderate scripting experience and above string seems to be perfectly valid to me.
How could I solve this issue? Really don't know what's the problem.

Only that problem prevents from switching from ubuntu(good distribution too), because I use laptop on the move,
so use of Wi-Fi is necessary for me. Also Arch is simpler to maintain, xfce on it works faster, uses
less resources and boots faster.

Thanks.

Last edited by bltsrc (2017-02-23 15:47:18)

Offline

#2 2017-02-20 17:54:25

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,449
Website

Re: How to cope with syntax error in vanilla pkgbuild.sh?

First, why are you trying to use wl?  Your card is supported by brcm80211 included in the kernel.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#3 2017-02-20 18:02:05

bltsrc
Member
Registered: 2017-02-20
Posts: 5

Re: How to cope with syntax error in vanilla pkgbuild.sh?

Yes, it's 14e4:4365 listed at https://wireless.wiki.kernel.org/en/use … rted_chips under the chipset
BCM4366.
And I have files in /lib/firmware/brcm
bcm4329-fullmac-4.bin    brcmfmac43236b.bin      brcmfmac4329-sdio.bin   brcmfmac43362-sdio.bin   brcmfmac4350-pcie.bin   brcmfmac43602-pcie.ap.bin
bcm43xx-0.fw        brcmfmac43241b0-sdio.bin  brcmfmac4330-sdio.bin   brcmfmac4339-sdio.bin    brcmfmac4354-sdio.bin   brcmfmac43602-pcie.bin
bcm43xx_hdr-0.fw    brcmfmac43241b4-sdio.bin  brcmfmac43340-sdio.bin  brcmfmac43430-sdio.bin   brcmfmac43569.bin       brcmfmac4366b-pcie.bin
brcmfmac43143.bin    brcmfmac43241b5-sdio.bin  brcmfmac4334-sdio.bin   brcmfmac43455-sdio.bin   brcmfmac4356-pcie.bin   brcmfmac4371-pcie.bin
brcmfmac43143-sdio.bin    brcmfmac43242a.bin      brcmfmac4335-sdio.bin   brcmfmac4350c2-pcie.bin  brcmfmac43570-pcie.bin

Still nm-applet doesn't show Wi-Fi connections and "ip link show" doesn't show wireless device nodes.
So I resorted to building dkms module from AUR package hoping that this will solve the problem.

Offline

#4 2017-02-21 11:59:51

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,868

Re: How to cope with syntax error in vanilla pkgbuild.sh?

That error is probably detected by pkgbuild.sh , but caused by something in the package you're trying to build.

Full build output please.

Last edited by Lone_Wolf (2017-02-21 12:00:05)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#5 2017-02-21 17:33:01

bltsrc
Member
Registered: 2017-02-20
Posts: 5

Re: How to cope with syntax error in vanilla pkgbuild.sh?

bash-4.4$ git clone https://aur.archlinux.org/broadcom-wl-dkms.git
Cloning into 'broadcom-wl-dkms'...
remote: Counting objects: 189, done.
remote: Compressing objects: 100% (114/114), done.
remote: Total 189 (delta 107), reused 149 (delta 73)
Receiving objects: 100% (189/189), 47.71 KiB | 0 bytes/s, done.
Resolving deltas: 100% (107/107), done.
bash-4.4$ cd broadcom-wl-dkms/
bash-4.4$ makepkg -si
/usr/share/makepkg/util/pkgbuild.sh: line 90: syntax error near unexpected token `<'
/usr/share/makepkg/util/pkgbuild.sh: line 90: `    done < <(grep_function "$funcname" "$attr_regex")'
bash-4.4$

I executed commands under non-root user.

Offline

#6 2017-02-22 12:44:24

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,868

Re: How to cope with syntax error in vanilla pkgbuild.sh?

downloading snapshot, extracting and running makepg -Crs works fine for me.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#7 2017-02-22 12:49:15

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,449
Website

Re: How to cope with syntax error in vanilla pkgbuild.sh?

Are you able to build other AUR packages?


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#8 2017-02-22 13:48:56

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,788
Website

Re: How to cope with syntax error in vanilla pkgbuild.sh?

For some reason, makepkg is being run with 'sh', not 'bash'. Please post the output of

pacman -Qkk bash pacman

As well as any shell configuration files you have modified (e.g. ~/.bashrc)


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#9 2017-02-22 20:09:02

bltsrc
Member
Registered: 2017-02-20
Posts: 5

Re: How to cope with syntax error in vanilla pkgbuild.sh?

WorMzy wrote:

For some reason, makepkg is being run with 'sh', not 'bash'. Please post the output of

pacman -Qkk bash pacman

As well as any shell configuration files you have modified (e.g. ~/.bashrc)

.bashrc:

[[ $- != *i* ]] && return

alias ls='ls --color=auto'
PS1='[\u@\h \W]\$ '

.bash_profile:

[[ -f ~/.bashrc ]] && . ~/.bashrc

Neither of them contains shebang.

pacman -Qkk bash pacman
bash: 235 total files, 0 altered files
backup file: pacman: /etc/makepkg.conf (Modification time mismatch)
backup file: pacman: /etc/makepkg.conf (Size mismatch)
pacman: 349 total files, 1 altered file

I modified /etc/makepkg by changing CFLAGS, CXXFLAGS.

makepkg -Crs fails with the same error as makepkg -si (which I use according to wiki).

"For some reason, makepkg is being run with 'sh', not 'bash'." I also think so.
My login shell is /bin/bash.

Last edited by bltsrc (2017-02-22 20:10:10)

Offline

Board footer

Powered by FluxBB