Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 657215
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T22:47:56+00:00 2026-05-13T22:47:56+00:00

I wrote a makefile: all: server client server: server.o des.o sha1.o /usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -o server

  • 0

I wrote a makefile:

all: server client
server: server.o des.o sha1.o
/usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -o server server.o des.o sha1.o -I /usr/local/include/ -lgmp 
client: client.o des.o sha1.o
/usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -o -lgmp client client.o des.o sha1.o -I /usr/local/include/ 
server.o: server.c
/usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -c -lgmp server.c -I /usr/local/include/
client.o: client.c
/usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -c -lgmp client.c -I /usr/local/include/
des.o: des.c des.h
/usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -c -lgmp des.c -I /usr/local/include/
sha1.o: sha1.c sha1.h /usr/local/arm-2009q1/bin/arm-none-linux-gnueabi-gcc -c -lgmp sha1.c -I /usr/local/include/

clean: -rm *.o server client

then gcc told me that cannot find -lgmp. I tried to put it in other places, there were other different errors…

In plus, I want to know if it’s possible to put 2 elements in the target.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T22:47:57+00:00Added an answer on May 13, 2026 at 10:47 pm

    You probably need to provide a -L option to the compiler to add the directory containing the gmp library to the list of directories searched.

    e.g.

    -L/usr/local/lib
    

    or

    -L/usr/local/arm-2009q1/lib
    

    As you appear to be cross-compiling you need a cross-compiled version of the gmp available in a path that you pass with a -L option.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I wrote a small makefile which follows the general structure, creating object files and
I wrote the following makefile, but I don't really understand what's going on (I
I have a following Makefile for tiobench. I wrote it. The problem is, when
I wrote a Makefile(code below) for my program which contains hello.h, hello.cpp and main.cpp
Here is an easy makefile. I have 2 questions. all: $(SOURCES) $(EXECUTABLE) Why put
I am trying to write a makefile for a small scale application I wrote
Wrote a quick Java proggy to spawn 10 threads with each priority and calculate
I wrote a symfony task to fill a database of sample data. Here's a
I wrote a process explorer using C with GUI interface. I want to add
I wrote some script in a site. The script makes a new spreadsheet and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.