![]() |
|
fblend, aastr,alfont |
jamdesalles
Member #16,737
September 2017
|
Instalei o Allegro 5 no meu Imac pois o Allegro 4 parece nãp ser suportado no High Sierra. Agradeço desde já ! José Antönio |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
Quote: "Eu instalei Allegro 5 no meu iMac porque o Allegro 4 parece ser Obrigado antecipadamente! " Allegro 4 não é mais suportado. Allegro 5 é suportado no mais recente OSX. Translated by translate.google.com Quote: "I installed allegro 5 in my IMAC because allegro 4 seems to be Thank you in advance! " Allegro 4 is no longer supported. Allegro 5 is supported on the latest OSX. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Ok, o que substitui estas funçoes, não conheço o allegro 5, semente o 4 ! Estou portando para o Imac um aplicativo escrito em 2010 ! |
jamdesalles
Member #16,737
September 2017
|
Grato pela ajuda ! Deu certo ! Porém tenho um problema ! Fiz um pequeno programa tipo Hello World para testar. Embora o Allegro 5 esteja instalado , está dano um erro na compilação estranho, ele reclama a ausência do Header <allegro5/allegro.h>, creio que isto não deveria estar acontecendo ! Em outro programa escrito no allegro 4, troquei para <allegro5/allegro> e isto não acontece ! Estranho ! Segue o programa e o Makefile : #include< allegro5/allegro.h > int principal () ALLEGRO_TIMER* temporizador = al_create_timer ( 1.0 / 30.0 ); al_register_event_source (fila, al_get_keyboard_event_source ()); bool redesenho = true ; al_start_timer (temporizador); if (evento. tipo == ALLEGRO_EVENT_TIMER) if (redesenhar && al_is_event_queue_empty (fila)) redesenhar = falso ; al_destroy_font (fonte); retorna 0 ; Makefile : all: caixa caixa: $(OBJECTS) .SUFFIXES: .c.o : count: clean: .PHONY: all |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
jamdesalles said: Thank you for help! It worked out ! But I have a problem! I made a small HELLO World program to test. Although Allegro 5 is installed, it is damage a strange compilation error, it complains the absence of the header <allegro5 / allegro.h>, I believe this should not be happening! In another program written on Allegro 4, I switched to <allegro5 / allegro> and this does not happen! Strange ! Follow the program and makefile: You need to set the search directory for include files so that it will find <allegro5/allegro.h> properly. Usually they are in /usr/include or /usr/local/include and you include them with -I /usr/DIRECTORY My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Obrigado, mas o -I /usr/DIRECTORY eu coloco no programa antes do #include ou dentro do #include ? |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
g++ -Wall -Wextra -g -I /usr/local/include -o prog.exe prog.cpp -lallegro_monolith-debug.dll
My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Obrigado mais uma vex ! Alterei que você indicou porém continua dizendo que não encontra o <allegro5/allegro5.h> ! CC = gcc all: teste teste : $(OBJECTS) .SUFFIXES: .c.o : count: clean: .PHONY: all Você tem ajudado muito ! O que preciso é de algum aplicativo ou ferramenta que permita portar o código do Allegro 4 para o Allegro 5 ? O Allegro 5 é muito diferente do 4 que conheço bem, os programas foram escritos por volta de de 2010 e estou passado para a plataforma do iMac e estou apanhando bastante com o Allegro 5. Os programas funcionam bem no Linux com o Allegro 4 porém estou tendo dificuldades na portabilidade. Quando falo da ferramenta (se é que existe) é algo que possa me indicar o que mudou do código do 4 para o 5. Estou portando para a plataforma iMAc ! Agradeço ! |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
https://github.com/liballeg/allegro_wiki/wiki/Installing-with-homebrew It says allegro should be in /usr/local/include . (Note the leading /) My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Mais uma vez obrigado ! Eu já havia corrigido e continua reclamando allegro5/allegro5.h not found ! Interessante é que em outros ela passa neste especificamente ele reclama ! A página indicada traz algo sobre algum recurso para o Allegro 4 portado para o allegro 5 ? |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
Okay, so you installed Allegro 5 using Homebrew? And changed it to -I /usr/local/include? The includes don't have any spaces. #include <allegro5/allegro.h> I don't know what else is wrong. For help porting allegro 4 programs to allegro 5, see a4_aux.c and a4_aux.h in Allegro/demos/speed. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
sim homebrew, tenho uma duvida o Allegro5 funciona no High Sierra ? Por favor me ajude ! 45 anos de de programação ! Assembler, C , C++, e outras ! To apanhando como iniciante ! O mundo Apple é novidade para mim, estou gostando muito ! Abandonei o Windows ! É outra coisa, muito intuitivo ! Mas em certas coisas ainda estou aprendendo ! Eterno Aprendiz ! o Allegro 5 funciona no High Sierra ou vou ter que atualizar, esta dando problema na compilação com x86-64 ! |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
jamdesalles - Allegro 5 may not be supported on High Sierra, so you may need to downgrade to Allegro 4. I can't find an answer on this. It would probably be good to invest in newer hardware for a Mac. 2010 is pretty old and won't be supported by many people. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Meu iMac é 2017 !!! |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
Then why are you running High Sierra? 10.13 My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Desculpe é 2011 ! |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
If High Sierra and your computer are both from 2017 then you should be able to install Homebrew, and then Allegro 5, like I said before. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
jamdesalles
Member #16,737
September 2017
|
Após apanhar muito consegui evoluir um pouco ! Agora está dando o seguinte problema, lembrando Allegro5 iMac com High Sierra :g++ -o bicho bicho.o -Wl,-rpath,/usr/local/lib -lallegro -lallegro_font -lallegro_main -lncurses -lmysqlclient |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
You have to link to the native dialog addon. -lallegro_dialog My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
Peter Hull
Member #1,136
March 2001
|
Sorry for lack of Portuguese. I would recommend using pkg-config (you may have it already or it's on homebrew). It will know which flags to apply to specify includes and libs (for things that homebrew installed). I would also use make's features a bit more, you don't have to tell it how to compile a c file, for example. I tested this on a Mac with MacOS Catalina. Makefile: CFLAGS = -g -Wall -Wextra `pkg-config --cflags allegro-5 allegro_main-5 allegro_font-5 allegro_dialog-5` OBJECTS = teste.o LDFLAGS = -g LDLIBS = `pkg-config --libs allegro-5 allegro_main-5 allegro_font-5 allegro_dialog-5` all: teste teste: $(OBJECTS) $(LINK.o) -o $@ $< $(LDLIBS) count: wc *.c *.cc *.C *.cpp *.h *.hpp clean: rm -f *.o teste .PHONY: all .PHONY: count .PHONY: clean
Also your source code is very strange and, I believe, not valid C. Did you run it through a language translator
|
jamdesalles
Member #16,737
September 2017
|
Estranho como ? Não te passei o código fonte ! |
Peter Hull
Member #1,136
March 2001
|
From your post on 9th April: jamdesalles said: Segue o programa e o Makefile And your file "programa" is strange, for example if (( tipo de evento == ALLEGRO_EVENT_KEY_DOWN) || ( tipo de evento == ALLEGRO_EVENT_DISPLAY_CLOSE)) isn't valid C - my guess is that event.type got translated to tipo de evento? Anyway it doesn't matter. I hope that Makefile helps you.
|
jamdesalles
Member #16,737
September 2017
|
Não ! este programa foi abandonado e estava usando o Allegro 4 ! Estou fazendo tudo outra vez em outro com o Allegro 5 ! Veja o resultado do Makefile que você sugeriu ! ele não encontra as bibliotecas ! Acho que não coloquei o nome correto , tentei usando todas com o -5 para identificar o Allegro5 e também deu o mesmo erro ! Veja o Makefile completo : CC = gcc all: bicho bicho: $(OBJECTS) .SUFFIXES: .c.o : count: clean: .PHONY: all Por favor me da uma luz !!!!! To parado e meu cliente me cobrando muito ! diuturnamente ! continua o problema do x86_64 ! : MacBook-Air-de-User:bicho maphiaimac$ make nos testes que fiz isto acontece no : video = al_create_display (1280, 1024); HELP !!!!!!! Por favor alguém me ajude !!! A coisa evolui mas sempre acontece algo novo ! o Allegro 5 é muito diferente ! Agora : Segue o fonte ! #include<allegro5/allegro_font.h> #define FUNDO 1 int main(int argc, char *argv[]) void init (void) // video = al_create_display (1280, 1024); al_show_native_message_box(NULL, "Message", "Ok ! : ", Lembrar que existe um tradutor que altera o conteúdo de algumas linhas, por exemplo não é retorno e sim return e outras também o código esta certo , porem este tradutor não sei por que altera ! ^ |
|