You are not logged in.

#1 2011-02-11 23:35:13

flan_suse
Member
Registered: 2010-10-28
Posts: 120

[SOLVED] Using $pkgname in the source array aborts with an error

Here is the PKGBUILD: http://archlinux.pastebin.com/FRgs3rrX

Here is the error: http://archlinux.pastebin.com/wDAWzCns

The package builds fine when I use the commented out line, instead:

source=('http://downloads.sourceforge.net/cupsdriverkodak/c2esp16.tar.gz')

For some reason, it aborts before even extracting the source tarball, only if I use variables in the URL for the source file:

source=('http://downloads.sourceforge.net/cupsdriverkodak/$pkgname$pkgver.tar.gz')

Other than that, the driver compiles with no problems, and the package installs without any issues, plus I am able to print to my Kodak ESP printer. It requires cups to be installed, but I'm hesitant to add cups as a dependency.

It would be nice to instead be able to use variables for the source line.

Last edited by flan_suse (2011-02-12 01:22:09)

Offline

#2 2011-02-11 23:38:30

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: [SOLVED] Using $pkgname in the source array aborts with an error

use double quotes when having variables in the link.

source=("http://downloads.sourceforge.net/cupsdriverkodak/$pkgname$pkgver.tar.gz")


Give what you have. To someone, it may be better than you dare to think.

Offline

#3 2011-02-12 01:20:19

flan_suse
Member
Registered: 2010-10-28
Posts: 120

Re: [SOLVED] Using $pkgname in the source array aborts with an error

wonder wrote:

use double quotes when having variables in the link.

Thank you! Marked as solved.

I always thought single quotes and double quotes were interchangeable, and they needed to be used together when containing a string within a string.

Offline

#4 2011-02-12 01:51:44

ngoonee
Forum Fellow
From: Between Thailand and Singapore
Registered: 2009-03-17
Posts: 7,360

Re: [SOLVED] Using $pkgname in the source array aborts with an error

flan_suse wrote:
wonder wrote:

use double quotes when having variables in the link.

Thank you! Marked as solved.

I always thought single quotes and double quotes were interchangeable, and they needed to be used together when containing a string within a string.

Double quotes allows variable substitutions, as you've found.


Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.

Offline

Board footer

Powered by FluxBB