Incorporate 2b version changes
The author made several changes since the version found here. Let's
pull those into the timeline and work them down into later revisions.
T. Joseph Carter
4 years ago
0 | For LinApple version 2b has been made: | |
1 | !! Fixed gcc version 4.8.4 <unistd.h> includes | |
2 | !! Some cleanup on Makefile, INSTALL, README and some others | |
3 | ||
0 | 4 | For LinApple version 2.0 has been made: |
1 | ||
2 | 5 | !! Fixed screen corruption bug for x64 systems |
3 | ||
4 | 6 | !! Fixed gcc 4.4 compilation error lacking <strings> |
5 | ||
6 | 7 | ++ FTP support. You can load disk images on Slots 6 (1 & 2) and Hard disks images, using FTP server such as apple.asimov.net |
7 | 8 | Press Alt+F3, Alt+Shift+F3 for load disk image through FTP |
8 | ||
9 | 9 | ++ Screen sizes are now flexible. You can set any screen size you wish, just be catious - not all screen sizes can work in full screen mode |
10 | ||
11 | 10 | ++ .zip images support for FDD 140K (in read-only mode). Just first file in .zip archive will be read and inserted as an image. |
12 | 11 | You can load .zip images directly from your file system (by F3/F4 keypress), or from FTP server (by pressing ALT+F3(F4)). |
13 | ||
14 | 12 | -- Sound is still glitched. Needs repairing. Please help! |
15 | 13 | |
16 | ||
17 | 14 | For LinApple version 1.1 has been added: |
18 | ||
19 | 15 | ++ 1. Opening of compressed .gz files - in read-only mode. Works only for FDD 140Kb drives. |
20 | ||
21 | 16 | ++ 2. Super quick load-save states (CTRL+0..9 - quick load state, CTRL+SHIFT+0..9 - quick save it) in current states directory. |
22 | ||
23 | 17 | ++ 3. Add Mockingboard (but not Phasor??) support, without speech, as I could take it. |
24 | 18 | But Mockingboard works! You may test it in such games as Berzap! (you need to switch Mockingboard on after pressing Ctrl+C in the game), in Willy Byte in the Digital Dimensions, in Pitfall II(tm), in UltimaIV and few others. |
25 | ||
26 | 19 | ++ 4. VideoBenchmark added! Run `linapple -b' to see benchmark running and its result in console. |
27 | ||
28 | 20 | ++ 5. Parallel Printer file name can be set in linapple.conf (default was Printer.txt in working directory) |
0 | Linapple - crossplatfom emulator of Apple][ (Apple2, Apple 2) series computer for Linux or other OSes with SDL support. | |
1 | ||
0 | Linapple - crossplatfom emulator of Apple ][ (Apple2, Apple 2e) series computer for Linux or other OSes with SDL support. | |
2 | 1 | |
3 | 2 | [INSTALL] |
4 | 3 | |
5 | You need SDL, cURL, zlib and libzip: | |
4 | You need SDL, cURL, zlib and libzip libraries development versions with -dev or -devel suffixes. | |
6 | 5 | |
7 | 6 | For Debian/Ubuntu their names are: |
8 | ||
9 | 7 | libsdl1.2-dev - Simple Direct Media crossplatform library for video,audio, events etc. |
10 | 8 | libcurl4 - openssl-dev - cURL net functions |
11 | 9 | zlib1g-dev - access .gz files |
14 | 12 | All these libraries are available for free around the world. |
15 | 13 | |
16 | 14 | For example for Debian/Ubuntu to install: |
17 | ||
18 | $sudo apt-get install libsdl1.2-dev libcurl4-openssl-dev zlib1g-dev libzip-dev | |
19 | ||
15 | $ sudo apt-get install libsdl1.2-dev libcurl4-openssl-dev zlib1g-dev libzip-dev | |
20 | 16 | |
21 | 17 | After being SDL, zlib, cURL and libzip installed you will be able to compile linapple from sources: |
22 | 18 | |
23 | 19 | Untar the package (in .bz2 format): |
24 | ||
25 | $ tar xjf linapple-src_2a.tar.bz2 | |
26 | ||
20 | $ tar xjf linapple_src-2b.tar.bz2 | |
27 | 21 | |
28 | 22 | Then go to src directory and compile. |
29 | ||
30 | $ cd linapple-src_2a/src | |
31 | ||
23 | $ cd linapple_src-2b/src | |
32 | 24 | $ make |
33 | 25 | |
34 | If there was no errors, you may install it if you wish: | |
35 | ||
26 | If there are no errors, you may install it if you wish: | |
36 | 27 | $ sudo make install |
37 | 28 | |
38 | It will be install in /usr/local/linapple folder, whre you can find linapple.conf file for changing some linapple settings, | |
39 | and empty `images` and `ftp` folders, where Apple 2 images files and downloaded through FTP images are meant to be in. | |
29 | It will be installed in /usr/local/linapple folder, whre you can find linapple.conf file for changing some linapple settings, | |
30 | and empty `images` and `ftp` folders, where Apple 2 images files and downloaded through FTP cached images are meant to be in. | |
40 | 31 | |
41 | But of course you are free to choose any directories of your choice. | |
42 | Note: you should read/write permissions of these folders, or linapple could not work properly. | |
32 | Of course you are free to choose any directories of your choice changing it in Makefile in src directory. | |
33 | Note: you should read/write permissions for these folders, or linapple could not work properly. | |
43 | 34 | |
44 | For linaaple ability to unpack .zip and .gz files on the fly (either from local disks or from FTP) you also need read/write access for linapple working | |
45 | folder (which by default is /usr/local/linapple), for linapple unpacks these files as drive0.dsk and drive1.dsk for drive 1 and 2 respectively. | |
35 | For linaaple ability to unpack .zip and .gz files on the fly (either from local disks or from FTP) you also need read/write access for linapple working folder (which by default is /usr/local/linapple), for linapple unpacks these files as drive0.dsk and drive1.dsk for drive 1 and 2 respectively. | |
46 | 36 | |
47 | ||
48 | OK. | |
49 | If you installed it, you are able to run emulator from any place, just run it like this: | |
50 | ||
37 | OK. If you installed it, you are able to run emulator from any place, just run it like this: | |
51 | 38 | $ linapple |
52 | 39 | |
53 | ||
54 | 40 | If you have chosen not to install it, go to the upper directory then and run the beast: |
55 | ||
56 | 41 | $ cd .. |
57 | ||
58 | 42 | $ ./linapple |
59 | ||
60 | 43 | |
61 | 44 | If all files are on their places, you should see an X-Window with splash screen. |
62 | 45 | Press F2 (or F3 before to choose some disk image in drive 1), and go to work. |
64 | 47 | Note: linapple needs some files in its current working directory for proper working. |
65 | 48 | |
66 | 49 | These files are: |
67 | ||
68 | 50 | splash.bmp - splash screen |
69 | 51 | charset40.bmp - charset for Apple][ (Apple 2e, etc.) text modes. |
70 | 52 | font.bmp - font for Help screen and Disk Select screens. |
71 | 53 | icon.bmp - nice icon, logo of Apple][ computer. |
72 | 54 | linapple.conf - configuration file. |
73 | Master.dsk - disk image with Applesoft(tm) DOS 3.3 inside. See Apple license (on apple.com) for details. | |
55 | Master.dsk - disk image with Applesoft(tm) DOS 3.3 inside. See Apple license (on apple.com) for details. | |
74 | 56 | |
75 | Essentials are font.bmp and charset40.bmp, others can be omitted peacefully. | |
57 | Essential are font.bmp and charset40.bmp, others can be omitted peacefully. | |
76 | 58 | |
77 | P.S. You may play with some options in Makefile in src directory, if you know what you are to do. :) | |
59 | P.S. You may play with some options in Makefile in src directory, if you know what you want to do. | |
78 | 60 | |
79 | 61 | Note: See README file for more detailed instructions on using linapple. |
80 | ||
81 | 62 | |
82 | 63 | [UNINSTALL] |
83 | 64 | |
84 | 65 | To uninstall previously installed linapple (by `sudo make install` command) you may write this: |
85 | ||
86 | 66 | $ sudo make uninstall |
87 | 67 | |
88 | 68 | This will remove by default entire `/usr/local/linapple` folder and `/usr/local/bin/linapple` script. |
89 | 69 | |
90 | ||
91 | 70 | Also there is possible command for cleaning compiled binaries in src directory: |
92 | ||
93 | 71 | $ make clean |
94 | 72 | |
95 | 73 | Note: `linapple` executable in upper directory will remain intact. |
96 | 74 | |
97 | ||
98 | ||
99 | 75 | [CONTACT] |
100 | 76 | |
101 | I will be glad to see your comments, suggestions and so on on my email: beotiger@gmail.com | |
77 | I will be glad to see your comments, suggestions and so on on my email beotiger@gmail.com | |
102 | 78 | |
103 | 79 | Sincerely Yours, |
104 | Krez beom beotiger, December 2007 AD - March 2012 AD | |
105 | ||
106 | beotiger@mail.ru | |
107 | beotiger@gmail.com | |
80 | beotiger, December 2007 AD - March 2012 AD - June 2015 | |
81 | http://beotiger.com beotiger@gmail.com | |
108 | 82 | |
109 | 83 | Let Apple 2 live forever! |
110 |
0 | *** LINAPPLE 2.0*** | |
0 | *** LINAPPLE 2b*** | |
1 | 1 | |
2 | 2 | [INTRO] |
3 | 3 | What is linapple? |
4 | 4 | It is an emulator of Apple2 (Apple][, Apple 2, Apple 2e etc.) computer series for Linux or other OSes with SDL support. |
5 | (SDL means Simple Direct Media Layer written by Sam Lantinga and others). | |
5 | 6 | |
6 | (SDL means Simple DirectMedia Layer written by Sam Lantinga and others). | |
7 | ||
8 | linapple works out of the box, just make it once and run whenever you wish. | |
7 | Linapple works out of the box, just make it once and run whenever you wish. | |
9 | 8 | |
10 | 9 | Why not AppleLin? Yes, at first I think to call it such, but later linapple seemed better to me. And one point! |
11 | ||
12 | 10 | This is my work for making it possible to have comprehensive emulator of Apple][ computer series in Linux. |
13 | ||
14 | 11 | The original source is from AppleWin (http://applewin.berlios.de) by Tom Charlesworth and others. |
15 | ||
16 | 12 | I just adapted it for: video+audio for SDL, other functions for POSIX compliant OS, which Linux is in particularly. |
17 | ||
18 | 13 | Later some sort of Windows support had been added, so you may try to compile it under Windows. |
19 | ||
20 | ||
21 | 14 | |
22 | 15 | [INSTALL] |
23 | 16 | |
24 | 17 | I will show brief instructions for compiling and installing linapple here. |
25 | ||
26 | 18 | Please, see INSTALL file for comprehensive installing tips. |
27 | ||
28 | After SDL1.2, zlib, libcurl and libzip are installed in your system, you can build sources. | |
19 | After SDL1.2, zlib, libcurl and libzip (development versions with -dev or -devel suffixes) are installed in your system, you can build sources. | |
29 | 20 | |
30 | 21 | Unpack downloaded linapple archive and go to src directory: |
31 | ||
32 | 22 | $ cd src |
33 | 23 | |
34 | 24 | Then run: |
35 | ||
36 | 25 | $ make |
37 | 26 | |
38 | 27 | or |
39 | ||
40 | 28 | $ sudo make install |
41 | 29 | |
42 | 30 | If there is no errors, run: |
43 | ||
44 | 31 | $ linapple |
45 | 32 | |
46 | 33 | or without being installed: |
47 | ||
48 | 34 | $ cd .. |
49 | 35 | $ ./linapple |
50 | 36 | |
56 | 42 | Where to install? Anywhere you feel fit, just let linapple be with some files it needs for comprehenceive working. |
57 | 43 | |
58 | 44 | These files are: |
59 | ||
60 | 45 | splash.bmp - splash screen |
61 | 46 | charset40.bmp - charset for Apple][ (Apple 2e, etc.) text modes. |
62 | 47 | font.bmp - font for Help screen and Disk Select screens. |
64 | 49 | linapple.conf - configuration file. |
65 | 50 | Master.dsk - disk image with Applesoft(tm) DOS 3.3 inside. See Apple license (on apple.com) for details. |
66 | 51 | |
67 | ||
68 | 52 | [USING LINAPPLE] |
69 | 53 | |
70 | At first start you should see some nice splashscreen. Press F2 to start emualtion. Master.dsk should load, and you will see an DOS3.3(tm) prompt. By pressing F3 you may select an image file name (usually having extensions .dsk, .do, .po) into Slot 6 Drive 1. After selecting it, you either may reboot anew (by pressing F2 key) and try to boot from the inserted disk, or type any DOS3.3(tm) commands to view disk contents and to run any program located in it. Common DOS commands are `CATALOG' (like `ls' in Linux), `BRUN FILENAME' - running any binary (B) program, or `RUN FILENAME' - running any Basic program (A or I). Usually, most game images have alternative way to run programs in them. You may find a lot of disk images on largest and oldest ftp for Apple][ stuff ftp.apple.asimov.net. | |
54 | At first start you should see some nice splashscreen. Press F2 to start emualtion. Master.dsk should load, and you will see an DOS3.3(tm) prompt. By pressing F3 you may select an image file name (usually having extensions .dsk, .do, .po) into Slot 6 Drive 1. After selecting it, you either can reboot anew (by pressing F2 key) and try to boot from the inserted disk, or type any DOS3.3(tm) commands to view disk contents and to run any program located in it. Common DOS commands are `CATALOG' (like `ls' in Linux), `BRUN FILENAME' - running any binary (B) program, or `RUN FILENAME' - running any Basic program (A or I). Usually, most game images have alternative way to run programs in them. | |
71 | 55 | |
72 | From version 2 of linapple you are able to download such images directly from FTP! Use Alt+F3 or Alt+F4 for charging drive 1 and drive 2 for slot 6 (if you know what I am about :) ) - they are just common disk sources of Apple 2 computer for reading/writing its files, such as system, games, utilities and so on. | |
56 | You may find a lot of disk images on may be the largest and the oldest ftp archive for various Apple ][ stuff - ftp.apple.asimov.net | |
57 | ||
58 | From version 2 of linapple you are able to download such images directly from FTP! Use Alt+F3 or Alt+F4 for charging drive 1 and drive 2 for slot 6 (if you know what I am about :) ) - they are just common disk sources of Apple 2 computer for reading/writing its files, such as system, games, utilities and so on. Change `FTP Local Dir` parameter in linnaple. conf file to point to some writable directory and make directory named `cache` inside it (install routine does it for you). | |
73 | 59 | |
74 | 60 | To quit emualtor peacefully, press F10. F6 toggles fullscreen mode, Scroll Lock toggles fullspeed mode. |
75 | 61 | |
116 | 102 | $ ./linapple -b - run VideoBenchmark and exit emulator. Note: if fullscreen mode is on in linapple.conf, then |
117 | 103 | VideoBenchmark will be runned in fullscreen mode. |
118 | 104 | |
119 | ||
120 | ||
121 | 105 | In version 2 besides FTP support there is also support for changable Window sizes (see at the end of linapple.conf file for details). |
122 | 106 | Just be aware when you are not running emulator on its native mode (560x384) you can suffer slowdown if you are using old box. |
123 | ||
124 | ||
125 | 107 | |
126 | 108 | [SUPPORT] |
127 | 109 | Wanted: |
128 | 110 | |
129 | -- we need to get rid of some SOUND glitches. HELP! | |
111 | -- We need to get rid of some SOUND glitches. HELP! | |
130 | 112 | |
131 | 113 | --DEBUGGER |
132 | 114 | I just owe at 9300 lines of code of AppleWin debugger. Michael Pohoreski, you are he-man, I tell you. |
133 | 115 | Besides Debugger.cpp alone, there are some helper files such as Debugger_Assembler.cpp, |
134 | 116 | Debugger_Console.cpp, Debugger_Display.cpp and so on. Who is able to port it to linapple? |
135 | ||
136 | 117 | |
137 | 118 | --PHASOR |
138 | 119 | Who knows how does that great thing work? Please, help adopting it to lianpple. |
140 | 121 | SDL Audio used. Speakers are working out in Speaker.cpp. Who may think, heh? |
141 | 122 | From version 1.1 Mockingboard support are done. |
142 | 123 | |
143 | ||
144 | ||
145 | 124 | More testing and debugging needed, of course. I would be grateful for any comment or suggestion regarding linapple, and using it on OSes other than Linux. |
146 | 125 | |
126 | [CONTACTS] | |
127 | I am beotiger, you may contact me at your will by my email beotiger@gmail.com | |
147 | 128 | |
148 | [CONTACTS] | |
149 | I am Krez beom beotiger (Kbb), you may contact me at your will by my email beotiger@gmail.com or beotiger@mail.ru | |
150 | ||
151 | Web-site: http://linapple.sourceforge.net | |
152 | ||
129 | Web-sites: | |
130 | http://beotiger.com | |
131 | http://linapple.sourceforge.net | |
153 | 132 | |
154 | 133 | Thank you very much. |
155 | 134 | Long Live Linux! |
157 | 136 | |
158 | 137 | -- |
159 | 138 | 24 March 2012 AD |
160 | beotiger@mail.ru | |
161 | ||
139 | 26 June 2015 AD |
167 | 167 | # |
168 | 168 | # Default: your home directory (if not set) |
169 | 169 | |
170 | Slot 6 Directory = | |
170 | Slot 6 Directory = /home/justy/Asimov.NET/action/bubble_bobble | |
171 | 171 | |
172 | 172 | # You may also provide images to be inserted in 1 and 2 drive (D1 or D2) of Slot 6 at startup |
173 | 173 | # Default: do not use, starting with image named Master.dsk in current directory |
174 | 174 | |
175 | 175 | # To get access to the disk in second drive(D2), use something like '] CATALOG,D2' at Applesoft DOS(tm) prompt. |
176 | 176 | |
177 | Disk Image 1 = | |
177 | Disk Image 1 = /home/justy/Asimov.NET/action/bubble_bobble/bubble_bobble2.dsk.gz | |
178 | 178 | Disk Image 2 = |
179 | 179 | |
180 | 180 | # The next parameter defines if you wish to auto-load these disk images in drives at startup! |
225 | 225 | # !!! Warning: FTP Local Dir should be existing directory with write access either FTP won't work |
226 | 226 | # Note : FTP Server MUST end with '/' sign either it won't work! FTP Local Dir should not end with '/' |
227 | 227 | |
228 | FTP Server = ftp://ftp.apple.asimov.net/pub/apple_II/images/games/ | |
228 | FTP Server = ftp://ftp.apple.asimov.net/pub/apple_II/images/games/action/ | |
229 | 229 | FTP ServerHDD = ftp://ftp.apple.asimov.net/pub/apple_II/images/ |
230 | 230 | FTP UserPass = anonymous:my-mail@mail.com |
231 | FTP Local Dir = | |
231 | FTP Local Dir = | |
232 | 232 | |
233 | 233 | ########################################################################## |
234 | 234 | # |
0 | 0 | # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
1 | 1 | # !! Note 1: this configuration file is for installed linapple |
2 | ||
3 | 2 | # !! If you have edited Makefile (in src directory of linaple package) |
4 | 3 | # !! to change INSTDIR - path where lianpple are to be installed |
5 | 4 | # !! you should consider change some paths for disk images and FTP local directory |
6 | 5 | # !! in order to let linapple find proper way to access needed stuff |
7 | 6 | |
8 | ||
9 | # !! Good luck to You! (beotiger: beotiger@mail.ru) | |
10 | ||
11 | ||
12 | 7 | # Note 2: Default install directory (for *nix) is /usr/local/linapple/ |
13 | 8 | # (defined in Make file in src directory as INSTDIR variable) |
14 | 9 | |
15 | ||
16 | 10 | # |
17 | 11 | # linapple.conf - config file used by LinApple, Apple][ (Apple2, Apple 2) emulator for Linux and other systems with SDL support |
18 | 12 | # |
21 | 15 | |
22 | 16 | # Remember - all lines beginning with '#' are considered comments. |
23 | 17 | # All values are CASE SENSITIVE, you should not use, for example, 'joystick 0' instead of 'Joystick 0'. |
24 | # | |
25 | ||
26 | 18 | |
27 | 19 | #################################################################### |
28 | 20 | # First of all let us determine our machine type |
264 | 256 | |
265 | 257 | # Screen factor = 1.5 |
266 | 258 | |
267 | ||
268 | 259 | # Note: if you want to use Screen Width and Screen Height directly, comment out `Screen factor` whole option |
269 | 260 | # otherwise they won't take effect |
270 | 261 | # Default Screen Width is 560, Screen Height is 384 |
271 | 262 | |
272 | # Screen Width = 800 | |
273 | # Screen Height = 600 | |
274 | ||
263 | Screen Width = 800 | |
264 | Screen Height = 600 |
35 | 35 | // define time when cache ftp dir.listing must be refreshed |
36 | 36 | #define RENEW_TIME 24*3600 |
37 | 37 | |
38 | char * | |
39 | md5str (const char *input); // forward declaration of md5str func | |
40 | ||
41 | TCHAR g_sFTPDirListing[512] = TEXT("/cache/ftp."); // name for FTP-directory listing | |
38 | char * md5str (const char *input); // forward declaration of md5str func | |
39 | ||
40 | TCHAR g_sFTPDirListing[512] = TEXT("cache/ftp."); // name for FTP-directory listing | |
42 | 41 | //////////////////////////////////////////////////////////////////////////////////////// |
43 | 42 | int getstatFTP(struct ftpparse *fp, int * size) |
44 | 43 | { |
113 | 112 | font_print_centered(sx/2 ,5 * facy , ftp_dir, screen, 1.5 * facx, 1.3 * facy); |
114 | 113 | if(ch) ftp_dir[NORMAL_LENGTH] = ch; //restore cut-off char |
115 | 114 | |
116 | font_print_centered(sx/2,20 * facy,"Connecting to FTP server... Please wait.", screen, 1 * facx, 1 * facy); | |
115 | font_print_centered(sx/2,20 * facy, "Connecting to FTP server... Please wait.", screen, 1 * facx, 1 * facy); | |
117 | 116 | SDL_Flip(screen); // show the screen |
118 | 117 | |
119 | 118 | bool OKI; |
122 | 121 | OKI = false; // use this file |
123 | 122 | } |
124 | 123 | else { |
125 | OKI = ftp_get(ftp_dir,ftpdirpath); // get ftp dir listing | |
124 | OKI = ftp_get(ftp_dir, ftpdirpath); // get ftp dir listing | |
126 | 125 | } |
127 | 126 | #else |
128 | 127 | // in WIN32 let's use constant caching? -- need to be redone using file.mtime |
27 | 27 | |
28 | 28 | /* Adaptation for SDL and POSIX (l) by beom beotiger, Nov-Dec 2007 */ |
29 | 29 | |
30 | /* And KREZ */ | |
31 | ||
30 | // for usleep | |
31 | #include <unistd.h> | |
32 | 32 | #include "stdafx.h" |
33 | 33 | //#pragma hdrstop |
34 | 34 | #include "MouseInterface.h" |
0 | 0 | CXX ?= c++ |
1 | 1 | CXXFLAGS ?= -O3 |
2 | CXXFLAGS += -Wall | |
2 | CXXFLAGS += -w | |
3 | 3 | |
4 | 4 | OBJS := $(filter-out Applewin.cpp Util_MemoryTextFile.cpp,$(wildcard *.cpp)) |
5 | 5 | OBJS := $(OBJS:.cpp=.o) |
22 | 22 | STARTUP = /usr/local/bin/$(EXE) |
23 | 23 | DATA = ../charset40.bmp ../font.bmp ../icon.bmp ../splash.bmp ../Master.dsk ../linapple.installed.conf |
24 | 24 | |
25 | #all: ../linapple | |
25 | .PHONY: all clean install uninstall | |
26 | ||
26 | 27 | all: $(EXE) |
27 | 28 | |
28 | 29 | Applewin: $(OBJS) |
31 | 32 | # $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ |
32 | 33 | mv $^ $@ |
33 | 34 | strip $@ |
34 | @echo " o If there are no errors, $(EXE) compiled succesfully" | |
35 | @echo " o $(EXE) compiled succesfully" | |
35 | 36 | cp $@ ../ |
36 | ||
37 | # static binary: (DOES NOT WORK) | |
38 | #static: $(OBJS) | |
39 | # $(CC) -static $^ -o $@ `sdl-config --static-libs` -ldl -lz | |
40 | # strip static | |
41 | # mv static ../$(EXE)-static | |
42 | 37 | |
43 | 38 | clean: |
44 | 39 | rm -f $(EXE) *.o |
45 | 40 | |
46 | .PHONY: all clean | |
47 | ||
41 | # | |
48 | 42 | # Installation routines |
43 | # | |
49 | 44 | |
50 | 45 | install: all |
51 | 46 | @echo " o Creating install directory '$(INSTDIR)'" |
52 | 47 | mkdir "$(INSTDIR)" |
53 | chmod 777 "$(INSTDIR)" | |
54 | 48 | @echo " o Creating additional directories 'images' and 'ftp' in '$(INSTDIR)'" |
55 | 49 | mkdir "$(INSTDIR)/images" |
56 | 50 | mkdir -p "$(INSTDIR)/ftp/cache" |
60 | 54 | |
61 | 55 | @echo " o Preparing configuration file 'linapple.conf'" |
62 | 56 | mv "$(INSTDIR)/linapple.installed.conf" "$(INSTDIR)/linapple.conf" |
63 | chmod 777 -R "$(INSTDIR)/" | |
64 | ||
65 | @echo " o Configuring access permissions for 'ftp' and 'images' directories" | |
66 | chmod 777 "$(INSTDIR)/images" | |
67 | chmod 777 "$(INSTDIR)/ftp" | |
68 | chmod 777 "$(INSTDIR)/ftp/cache" | |
57 | chmod -R 777 "$(INSTDIR)/" | |
69 | 58 | |
70 | 59 | @echo " o Creating startup script $(STARTUP)" |
71 | 60 | echo "cd \"$(INSTDIR)\"; ./$(EXE); cd -" >"$(STARTUP)" |
72 | 61 | chmod 755 "$(STARTUP)" |
73 | 62 | |
74 | 63 | @echo "" |
75 | @echo "Type '$(EXE)' (no quotes) to start the beast!" | |
64 | @echo "Type $(EXE) to start the beast!" | |
76 | 65 | @echo "To change some settings edit \"$(INSTDIR)/linapple.conf\"" |
77 | 66 | |
78 | 67 | uninstall: |
80 | 69 | rm -rf "$(INSTDIR)" |
81 | 70 | @echo " o Removing startup script $(STARTUP)" |
82 | 71 | rm -f "$(STARTUP)" |
83 | @echo " o All done!" | |
84 | ||
72 | @echo " o All done! Linapple has been successfully removed from your system" |