Guest User

Untitled

a guest
May 27th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.32 KB | None | 0 0
  1. $ gcc -s -o scall scall.s
  2. scall.s: Assembler messages:
  3. scall.s:2: Error: no such instruction: `section '
  4. scall.s:4: Error: no such instruction: `global _start'
  5. scall.s:7: Error: unsupported instruction `mov'
  6. scall.s:8: Error: unsupported instruction `mov'
  7. scall.s:11: Error: operand size mismatch for `int'
  8. scall.s:13: Error: no such instruction: `section .data'
  9. scall.s:15: Error: no such instruction: `msglength .word 12'
  10.  
  11. section .text
  12. global _start
  13.  
  14. _start:
  15. mov 4,%eax
  16. mov 1,%ebx
  17. mov $message,%ecx
  18. mov $msglength,%edx
  19. int $0x80
  20.  
  21. section .data
  22. message: .ascii "Hello world!"
  23. msglength .word 12
  24.  
  25. .section .text
  26. .global _start
  27. _start:
  28. mov $4,%eax
  29. mov $1,%ebx
  30. mov $message,%ecx
  31. mov msglength,%edx
  32. int $0x80
  33.  
  34. mov $1, %eax
  35. mov $0, %ebx
  36. int $0x80
  37. .section .data
  38. message: .ascii "Hello world!"
  39. msglength: .word 12
  40.  
  41. .section .text
  42. .global main
  43. main:
  44. mov $4,%eax
  45. mov $1,%ebx
  46. mov $message,%ecx
  47. mov msglength,%edx
  48. int $0x80
  49.  
  50. mov $1, %eax
  51. mov $0, %ebx
  52. int $0x80
  53. .section .data
  54. message: .ascii "Hello world!"
  55. msglength: .word 12
  56.  
  57. .text
  58.  
  59. _start:
  60. .global main
  61.  
  62. main:
  63. mov 4,%eax
  64. mov 1,%ebx
  65. mov $message,%ecx
  66. mov $msglength,%edx
  67. int $0x80
  68.  
  69. .data
  70. message: .ascii "Hello world!"
  71. msglength: .word 12
Add Comment
Please, Sign In to add comment