alves077 Posted September 6, 2013 at 09:04 PM Report #523720 Posted September 6, 2013 at 09:04 PM Boa noite, Estou a tentar compilar um programa onde uso a biblioteca 'crypt', mas não estou a conseguir. Já andei a pesquisar, mas nada até agora. Penso estar a fazer o necessário.. #define PIPE_NAME "connect" #define _XOPEN_SOURCE #define _GNU_SOURCE #include <unistd.h> #include <crypt.h> #include <stdio.h> #include <stdlib.h> #include <time.h> #include <math.h> #include <sys/types.h> #include <sys/wait.h> #include <sys/time.h> #include <signal.h> #include <string.h> #include <fcntl.h> #include <sys/stat.h> #include <assert.h> #include <errno.h> (..) Tenho um simples makefile, com o comando gcc -lm -lcrypt -o teste teste.c A resposta diz me sempre: referência indefinida a `crypt'. Isto tudo no sistema xubuntu. Alguém que saiba o que me está a faltar? Obrigado pela atenção, alves077
HappyHippyHippo Posted September 6, 2013 at 10:43 PM Report #523736 Posted September 6, 2013 at 10:43 PM tens a certesa que é crypt ... tenho um feeling que terá outro nome ... IRC : sim, é algo que ainda existe >> #p@p Portugol Plus
alves077 Posted September 7, 2013 at 11:16 AM Author Report #523751 Posted September 7, 2013 at 11:16 AM O que me gera confusão é que tinha outro sistema e estava funcionável... Mas não é a lib crypt.h que tenho que importar? E depois usar a flag -lcrypt ?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now