View Issue Details

IDProjectCategoryView StatusLast Update
0000034elrepo wiki--wiki--OTHER--public2009-09-28 08:03
ReporterSlubek Assigned Toburakkucat  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionno change required 
Summary0000034: Unexpected end of file error when using kmodspec template file
DescriptionDuring prep stage of building package based on kmodspec file copied from http://elrepo.org/tiki/kmodspec , I got an 'Unexpected end of file' error.
Additional InformationError is caused by spaces before 'EOF' in:
---
for kvariant in %{kvariants} ; do
    %{__cp} -a %{kmod_name}-%{version} _kmod_build_$kvariant
    %{__cat} <<-EOF >_kmod_build_$kvariant/%{kmod_name}.conf
        override %{kmod_name} * weak-updates/%{kmod_name}
        EOF
done
---

It has to be like this:

---
for kvariant in %{kvariants} ; do
    %{__cp} -a %{kmod_name}-%{version} _kmod_build_$kvariant
    %{__cat} <<-EOF >_kmod_build_$kvariant/%{kmod_name}.conf
        override %{kmod_name} * weak-updates/%{kmod_name}
EOF
done
---
TagsNo tags attached.

Relationships

has duplicate 0000040 closedtoracat Syntax error in kmodspec 

Activities

burakkucat

2009-09-28 07:59

administrator   ~0000131

Last edited: 2009-11-30 08:46

This issue is a direct result of the way you have copied the template file.

Do not expand tabs to spaces when copying it. The following code segment is correct:

for kvariant in %{kvariants} ; do
    %{__cp} -a %{kmod_name}-%{version} _kmod_build_$kvariant
    %{__cat} <<-EOF >_kmod_build_$kvariant/%{kmod_name}.conf
        override %{kmod_name} * weak-updates/%{kmod_name}
        EOF
done

Please note that there is a <tab> character on each line before the "override" and the "EOF". You have missed the meaning of the "<<-EOF" construct for the "here" document.

Issue History

Date Modified Username Field Change
2009-09-27 16:06 Slubek New Issue
2009-09-27 16:06 Slubek Status new => assigned
2009-09-27 16:06 Slubek Assigned To => toracat
2009-09-28 07:59 burakkucat Note Added: 131
2009-09-28 07:59 burakkucat Assigned To toracat => burakkucat
2009-09-28 08:03 burakkucat Status assigned => resolved
2009-09-28 08:03 burakkucat Resolution open => no change required
2009-11-30 08:46 burakkucat Note Edited: 131
2009-11-30 08:47 burakkucat Relationship added has duplicate 0000040