program 001 - Hello World with C library
architecture x86-64
assembler nasm

main.asm

        extern puts
        global main

        section .rodata
msg:    db "Hello World!", 0

        section .text
main:
        ;;  puts (msg)
        mov rdi, msg
        call puts wrt ..plt

        ;;  return 0
        mov eax, 0
        ret

build instructions

nasm -f elf64 -o main.o main.asm
gcc -pie -o main main.o