delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/06/05/03:36:09

X-Spam-Flag: YES
X-Spam-Check-By: sourceware.org
Message-ID: <008f01c68872$a244e070$ab01a8c0@loiscxf>
From: "cxf" <chenxiaof AT is DOT iscas DOT ac DOT cn>
To: <cygwin AT cygwin DOT com>
Subject: How to use openssl in cygwin
Date: Mon, 5 Jun 2006 15:35:35 +0800
MIME-Version: 1.0
X-Mailer: Microsoft Outlook Express 6.00.2900.2869
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Note-from-DJ: This may be spam

Hi,all:
    I installed the Cygwin which is the Full version.
    I write the Program as the following:
    #include <openssl/evp.h>
    int  main()
    {
     EVP_MD_CTX md_ctx;
     unsigned int result_size;
     int rv;
     rv = EVP_SignInit(&md_ctx, EVP_sha1());
     return rv;
    }

   It is very simple,then I compile the program using the Cygwin(the 
file name is example.c)
    gcc -c example.c
    gcc -lcrypto -o example example.o

    but the gcc give out the error:
    undefined  reference to '_EVP_sha1'
    undefined  reference to '_EVP_DigestInit'

    I have checked that the libcrypto.a is in the right way.
    I doubt whether the libcrypto.a have the function: EVP_sha1 and 
EVP_DigestInit.

    (I compile the example.c in Linux,It is OK!)




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019