• Home
  • Disclaimer
  • Contact
  • Archives
  • About
  • Subscribe
  • Support
  • Advertise

Kernel Talks

Unix, Linux, & Cloud!

  • How-to guides
    • Howto
    • Disk management
    • Configurations
    • Troubleshooting
  • OS
    • HPUX
    • Linux
  • Miscellaneous
    • Software & Tools
    • Cloud Services
    • System services
    • Virtualization
  • Certification Preparations
    • AWS Certified Solutions Architect – Associate
    • AWS Certified Solutions Architect – Professional
    • AWS Certified SysOps Administrator – Associate
    • AWS Certified Cloud Practitioner
    • Certified Kubernetes Administrator
    • Hashicorp Certified Terraform Associate
    • Oracle Cloud Infrastructure Foundations 2020 – Associate
  • Tips & Tricks
  • Linux commands
You are here: Home / Troubleshooting Errors

How to resolve the fatal error: curses.h: No such file or directory

Published: March 16, 2017 | Modified: June 19, 2020



Learn how to get rid of the fatal error: curses.h: No such file or directory during utility or third-party package installations in Linux.

Solution for curses.h: No such file or directory

Many times during package/utility installations you must have come across an error like one below :

fatal error: curses.h: No such file or directory

Recently I faced it while installing cmatrix from source code. I saw an error like one below :

# make
gcc -DHAVE_CONFIG_H -I. -I. -I.     -g -O2 -Wall -Wno-comment -c cmatrix.c
cmatrix.c:37:20: fatal error: curses.h: No such file or directory
 #include <curses.h>
                    ^
compilation terminated.
make: *** [cmatrix.o] Error 1

After troubleshooting I came up with a solution and able to pass through make stage. I am sharing it here which might be useful for you.

curses.h header file belongs to ncurses module! You need to install packages ncurses-devel, ncurses (YUM) or libncurses5-dev (APT) and you will be through this error.

Use yum install ncurses-devel ncurses for YUM based systems (like Red Hat, CentOS, etc.) or apt-get install libncurses5-dev for APT based systems (like Debian, Ubuntu, etc.) Verify once that package is installed and proceed with your next course of action.

Follow category ‘Troubleshooting errors‘ for more such error based solutions.

⇠ Previous article
How to check if the package is installed on Linux
Next article ⇢
AWS cloud terminology

Related stuff:

  • How to unmount NFS when the server is offline
  • mount.nfs: requested NFS version or transport protocol is not supported
  • How to resolve mount.nfs: Stale file handle error
  • networker service not starting
  • device eth0 does not seem to be present, delaying initialization error on Linux VM
  • Access denied error in NFS for root account
  • How to resolve 83h/80h error in HPUX
  • 11 log files you should see on your Linux system
  • check_mk error Cannot fetch deployment URL via curl error
  • pvcreate error: Device /dev/xyz not found (or ignored by filtering).
  • VMware tools not running after Linux kernel upgrade
  • How to troubleshoot RPC: Port mapper failure – Timed out error

Filed Under: Troubleshooting Errors Tagged With: curses.h error, fatal error: curses.h: No such file or directory, make command failed with curses.h file not found

If you like my tutorials and if they helped you in any way, then

  • Consider buying me a cup of coffee via paypal!
  • Subscribe to our newsletter here!
  • Like KernelTalks Facebook page.
  • Follow us on Twitter.
  • Add our RSS feed to your feed reader.

Comments

  1. John Ahearn says

    May 18, 2019 at 8:11 am

    nope. didn’t work. sounded like you knew what you were talking about tho!

    Reply
  2. 01101001b says

    October 1, 2020 at 1:45 am

    It worked perfectly! Thank you so much!

    Reply
  3. enos says

    August 28, 2023 at 12:41 am

    it worked on redhat 9 while trying to get PacVim to work, I was getting error:
    ———
    src/helperFns.h:24:10: fatal error: cursesw.h: No such file or directory
    24 | #include

    ——
    It’s now resolved thanks your post. I appreciate it.

    Reply

Share Your Comments & Feedback: Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Get fresh content from KernelTalks

  • Email
  • Facebook
  • RSS
  • Twitter

Get Linux & Unix stuff right into your mailbox. Subscribe now!

* indicates required

This work is licensed under a CC-BY-NC license · Privacy Policy
© Copyright 2016-2023 KernelTalks · All Rights Reserved.
The content is copyrighted to Shrikant Lavhate & can not be reproduced either online or offline without prior permission.