blueecho's collection

누군가에게 "당신은 무엇을 잘하십니까?"라는 질문을 들었을때 바로 대답할것을 만들어보자~!!
        
분류 전체보기 (267)
NeWs (21)
배움생활 (107)
리눅스 (51)
SoC (29)
외부스터디 (2)
학교수업관련 (3)
일본어공부 (1)
ETC (21)
취미생활 (118)
끄적끄적 (5)
인생설계 (12)
Wish list (4)
자전거 Fedora 사진 솔카당 지름신 리눅스 연구실 생활 연구실생활 일본소설 영화감상
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
블로그 이동하였습니다.

 

배움생활/리눅스에 해당하는 글 51개
2005.12.27   make (1) 
2005.12.20   wxDev-CPP 설치 가이드 
2005.11.21   리눅스 에서 iso 이미지 화일 마운트 하기 

  make (1) | 2005. 12. 27. 17:01 | 배움생활/리눅스   
1. make에서의 명령은 'tab문자'를 인식하여 실행을 한다. 즉, 탭문자가 젤 먼저 나와야 명령으로 인식한다.
2. make에서의 매크로의 정의는 '='을 사용하며, 정의된 매크로를 사용할 때에는 $(),${},$등을 사용한다.
3. 기술파일(makefile)보다 자신의 정의한 매크로를 사용하기 위해서는 -e옵션을 사용하도록 한다.
4. 매크로에서는 문자열 치환을 할 수 있다. 예를 들면 "SRCS = defs.c redraw.c calc.c"라고 정의하고 사용시 "ls ${SRCS:.c=.o}"라고 사용하면 SRCS라고 정의되었던 부분의 .c를 .o로 치환해서 결과를 내보낸다. 결과는 "defs.o redraw.o calc.o"이다. 단 매크로의 마지막 부분이나 공백문자 바로앞까지만 적용된다.
5. $@은 현재 타겟의 이름이다
6. $?은 현재 타겟보다 최신인 필요항목들을 말한다. 현재 타겟의 종속적인 것들(타겟을 위해 컴파일이나 링크되어야 되는 것들)중 최신의 것을 말한다.(갱신이 필요없는 것은 사용하지 않는다)

'배움생활 > 리눅스' 카테고리의 다른 글

make (3)  (0) 2006.01.03
make (2)  (0) 2005.12.28
wxDev-CPP 설치 가이드  (0) 2005.12.20
리눅스 에서 iso 이미지 화일 마운트 하기  (0) 2005.11.21
페도라에 NTFS모듈 설치하기  (0) 2005.10.19


  wxDev-CPP 설치 가이드 | 2005. 12. 20. 16:40 | 배움생활/리눅스   
출처 : http://wiki.wxwidgets.org/wiki.pl?Dev-CPP_Setup_Guide


Dev-CPP Setup Guide
This page describes the steps I took in order to get Dev-Cpp to work with a homebuilt wxWidgets. I was using Dev-Cpp 4.9.8.1 and wxWidgets 2.5 from CVS.


Preparing Dev-Cpp

Download Dev-Cpp from http://www.bloodshed.net/dev/index.html
Download the wxWidgets DevPak http://michel.weinachter.free.fr/WxWindows-2.4.2.DevPak . You may not actually need this, but it conveniently installs some things into Dev-Cpp for you, so I think its useful.
Download http://michel.weinachter.free.fr/imagelib-2.DevPak as well.
You could also download the contrib devpack for some useful controls http://michel.weinachter.free.fr/WxWindows-2.4.2-contribs.DevPak.
Install Dev-Cpp, just following the installer directions. It would be wise to make sure there are no spaces anywhere in the path.
Install the imagelib DevPak by double-clicking it in your explorer window. This must be done before the next step, and (obviously) after the previous one.
Install the wxWidgets DevPak by double-clicking it in your explorer window.
Now you have Dev-Cpp installed, and you can happily program wxPrograms. However, the wxWidgets build is not tailored to your system, ESPECIALLY in the regard that you have a final build of the wxWidgets libraries. This is good for production releases of your applications, but not so good for development. I, for one, spend quite a bit of time debugging any applications I create.

So, now we've discovered that we really need to have a homebuilt version of wxWidgets, with debugging information made available to us. This is how I got involved in the making of this wiki page; there is surprisingly little information out there to describe the integration of Dev-Cpp with wxWidgets. Now that I'm finished, perhaps it wasn't really all that hard.

Anyhow, on to building our own copy of wxWidgets.


Building your own wxWidgets Library
Download MSYS and compile wxWidgets as described in Compiling wxWidgets with MSYS/MinGW

At this point, you should have a working 'debug' version of wxWidgets. Now we need to integrate it with Dev-Cpp.


Integrating Dev-Cpp with the new Library

Run Dev-Cpp.
Open a wxWidgets project, and open the project options dialog.
On the Parameters tab, enter the following for your c++ compiler options. ( -D__WXDEBUG__ -D__WXMSW__ -g -O0 -mthreads -Wall )
On the Parameters tab, enter the following for your linker options. ( -mthreads -Wl,--subsystem,windows -mwindows -lwx_mswd-2.5 -lwxjpegd -lwxpngd -lwxzlibd -mthreads -lrpcrt4 -loleaut32 -lole32 -luuid -lwinspool -lwinmm -lshell32 -lcomctl32 -lcomdlg32 -lctl3d32 -ladvapi32 -lwsock32 -lgdi32 -ltiff ) Note the library lwx_mswd-2.5. That will likely change depending on how your configure your build, and which version you are building, so just find it in the build lib folder, and grab the right name. ( libwx_mswd-2.5.a --> lwx_msw-2.5 )
On the Directories|Library tab, enter the lib directory for your special build. ( mine is C:\wx\msw-debug\lib )
On the Directories|Include tab, enter at least the following, per your own build :
( C:\wx\msw-debug\lib\wx\include\mswd-2.5 )
( C:\wx\include ) Note this is the MAIN include for your distribution, and not your special build.

Notes:
You may need to go into Tools|Compiler Options|Programs and change make.exe to mingw32-make.exe
If you get an error about "duplicate sections" you probably have an old copy of one of the libs floating around.

Conclusion
Now, that should be all that is needed. Your Dev-Cpp ought to work with your new build now. To be careful, you might want to dive into the Dev-Cpp directories, and remove the earlier installed copy of wx and its include folder.

I hope this page is of some benefit to somebody. It took me a very long time to get everything working correctly.

Enjoy!


Common problems

Undefined reference to: .... while linking
If you have added all the neccesary library files to the linker options and there are still unresolved references you might have come around a rather strange "feature" of gcc (g++ 3.2): it's picky about the order you place the libraries. If you are using the xrc resource system the wxxrc library should come first. Then comes wxmsw and then the rest of the (wx)libraries you use. Set the following as linker settings and all should work fine:

-mwindows -Wl,--subsystem,windows -mwindows -lwxxrc -lwxmsw -lstdc++ -lgcc -lodbc32 -lwsock32 -lwinspool -lwinmm -lshell32 -lcomctl32 -lctl3d32 -ladvapi32 -lopengl32 -lglu32 -lole32 -loleaut32 -luuid


Undefined reference to: png_blablabl while linking
If you're using wx/image.h (and maybe other things), you need to add the following libraries to the project settings as linker options:

-lpng -ltiff -ljpeg -lzlib


Cannot find -lwxmsw24
Maybe the library file is called slightly different. Look into the lib/ directories for a file called something like 'libwxmsw.a'.


Cannot find resource file
If you want to use wxWidgets resources (as for example the examples do), you need to add the '\dev-cpp\wx\include' (from the top of my head is that the correct path?) directory to the 'resource file directories' in the project settings.


File not found during make
If making fails with something like:


process_begin: CreateProcess((null), D:Dev-C++Binmake -C ../../src/regex -f
make
file.g95 WXDIR=../.. WXWIN=../.., ...) failed.
make (e=2): Le fichier specifu est introuvable

(translation: "the specified file cannot be found")

you're either:

not using the correct 'make' program: you should use MSYS make.
making a mistake in the path to the 'extra tools'
not having cp.exe installed
Solution for the latter:

- Download UnxUtils.zip from http://www.hristov.com/andrey/projects/php_stuff/UnxUtilsDist.html - Copy UnxUtils\usr\local\wbin\cp.exe to Dev-Cpp\bin\cp.exe




Dev-CPP Alternate Setup Guide
Dev-C++ is a nice Free IDE for Windows that works quite well with wxWidgets. See their website [here]

There is a binary package available in devpak (Dev-Cpp package format) available [here], don't get the version from vUpdate (it is old). You need to install the newest (beta) version of devc++, but generally, it's worth it.

If you would prefer to build wxWidgets from the sources (recommended for those who can) download 2.4.0 and follow the MinGW build instructions in docs/msw/install.txt

See also:


There is an extensive tutorial on setting up wxWidgets with Dev-C++ at http://www.upcase.de (nice page, there is also a precompiled DevPak at this page; just make sure to not follow the advice about "Copy this setup.h up one level").
There is an small tutorial in french on setting up wxWidgets with Dev-C++ at http://etud.epita.fr:8000/~nowick_c/publications/wxbloodshed_dev_cpp/
http://www.wxwidgets.org/devcpp.htm (Using wxWidgets with Dev-C++ on the wxWidgets web site)
wxWidgets 2.5.2 DevPak : Available from http://the-agency.sourceforge.net
The Agency Project has released an improved wxWidgets version 2.5.2 DevPak. This DevPak has been constructed to more closely reflect the configuration of a Visual Studio build and resolves platform dependent issues present in the previous release. The DevPak, wxWidgets-2.5.2-msw-mingw.DevPak, release is available from http://the-agency.sourceforge.net

'배움생활 > 리눅스' 카테고리의 다른 글

make (2)  (0) 2005.12.28
make (1)  (0) 2005.12.27
리눅스 에서 iso 이미지 화일 마운트 하기  (0) 2005.11.21
페도라에 NTFS모듈 설치하기  (0) 2005.10.19
wget을 이용한 다운로드...  (0) 2005.10.19


  리눅스 에서 iso 이미지 화일 마운트 하기 | 2005. 11. 21. 01:03 | 배움생활/리눅스   
이미지 화일을 받고 걱정하지 마세요
리눅스는 이미지 화일을 볼수있는 방법이 있습니다

mount -t iso9660 -r -o loop /FC.iso /media/cdrom

하시면은 아주 쉽겠 마운트 하여 그내용을 볼수 있습니다

-- 이솝보드따라하기 모임의 이장호님의 글을 옮겨왔습니다.

'배움생활 > 리눅스' 카테고리의 다른 글

make (1)  (0) 2005.12.27
wxDev-CPP 설치 가이드  (0) 2005.12.20
페도라에 NTFS모듈 설치하기  (0) 2005.10.19
wget을 이용한 다운로드...  (0) 2005.10.19
^M을 없애 보자...  (0) 2005.09.14


#1 #··· #13 #14 #15 #16 #17
 
     
- Home
- Guestbook
- Manage - Location
- Tag - Post