You all were kind enough to help me recently with understanding this language a bit better. I'm working on AT&T syntax x86_64 assembly language through an Apress book. The author gives this code, which, amazingly, I understand fairly well. But obviously not as well as I'd like. It won't link. I get undefined reference errors for the six "name" labels defined at the top (gkcname, et al.). I've checked the code to make sure it matches the author's many times over. It does.
The code is meant to be linked with another file, but I consolidated things and tried placing the entry point right here in this file just to be sure that wasn't related to the problem. Same error. I'm a complete newbie so I'm sure I'm missing something obvious. Help would be appreciated. Thank you again. All the best.
.section .data gkcname: .ascii "Gilbert Keith Chester\0" jbname: .ascii "Jonathan Bartlett\0" cslname: .ascii "Clist Silver Lewis\0" taname: .ascii "Tommy Aquinas\0" inname: .ascii "Isaac Newn\0" gmname: .ascii "Gregory Mend\0" .globl people, numpeople numpeople: .quad (endpeople-people)/PERSON_RECORD_SIZE people: .quad $gkcname, 200, 10, 2, 74, 20 .quad $jbname, 280, 12, 2, 72, 44 .quad $cslname, 150, 8, 1, 68, 30 .quad $taname, 250, 14, 3, 75, 24 .quad $inname, 250, 10, 2, 70, 11 .quad $gmname, 180, 11, 5, 69, 65 endpeople: .globl NAME_PTR_OFFSET, WEIGHT_OFFSET, SHOE_OFFSET .globl HAIR_OFFSET, HEIGHT_OFFSET, AGE_OFFSET .equ NAME_PTR_OFFSET, 0 .equ WEIGHT_OFFSET, 8 .equ SHOE_OFFSET, 16 .equ HAIR_OFFSET, 24 .equ HEIGHT_OFFSET, 32 .equ AGE_OFFSET, 40 .globl PERSON_RECORD_SIZE .equ PERSON_RECORD_SIZE, 48