Skip to content

Readme Troubleshooting Update Suggestion #312

Description

@jdjphoto

When users attempt to include the cs50.h header for C on Fedora 39 via command make -lcs50 phonebook they will run into the following output:

cc phonebook.c -o phonebook /usr/bin/ld: /tmp/ccYgcD5t.o: in function `main': phonebook.c:(.text+0x18): undefined reference to `get_string' /usr/bin/ld: phonebook.c:(.text+0x2b): undefined reference to `get_int' /usr/bin/ld: phonebook.c:(.text+0x42): undefined reference to `get_string' collect2: error: ld returned 1 exit status make: *** [<builtin>: phonebook] Error 1

The error listed in in README.md;
error while loading shared libraries: libcs50.so.8: cannot open shared object file: No such file or directory
won't be encountered unless they've attempt to compile with:
gcc -lcs50 phonebook.c -o phonebook
which they likely won't know to attempt during the Week 1 - Supersection lecture without having done C tutorials elsewhere.

Fedora users should probably be directed to add export LD_LIBRARY_PATH=/usr/local/lib to the bottom of .bashrc during the extract/install process as problems like this are very common in Fedora and its documentation and online help is limited.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions