forked from NVIDIA/gdrcopy
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
412 lines (348 loc) · 15.2 KB
/
Copy pathMakefile
File metadata and controls
412 lines (348 loc) · 15.2 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
# Copyright (c) 2019-2021, NVIDIA CORPORATION. All rights reserved.
# Copyright (c) 2025, Moore Threads Technology Co., Ltd. All rights reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
prefix ?= /usr
exec_prefix ?= $(prefix)
# Architecture support - default to x86_64
ARCH ?= x86_64
# Map architecture to multiarch directory name and Debian package architecture
ifeq ($(ARCH),x86_64)
MULTIARCH_DIR = x86_64-linux-gnu
DEB_ARCH = amd64
RPM_ARCH = x86_64
else ifeq ($(ARCH),aarch64)
MULTIARCH_DIR = aarch64-linux-gnu
DEB_ARCH = arm64
RPM_ARCH = aarch64
else ifeq ($(ARCH),arm64)
MULTIARCH_DIR = aarch64-linux-gnu
DEB_ARCH = arm64
RPM_ARCH = aarch64
else
# Fallback to standard lib directory
MULTIARCH_DIR =
DEB_ARCH = $(ARCH)
RPM_ARCH = $(ARCH)
endif
# Set libdir based on architecture
ifeq ($(MULTIARCH_DIR),)
libdir ?= $(exec_prefix)/lib
DEB_LIBDIR ?=
else
libdir ?= $(exec_prefix)/lib/$(MULTIARCH_DIR)
DEB_LIBDIR ?= $(MULTIARCH_DIR)
endif
bindir ?= $(exec_prefix)/bin
includedir ?= $(prefix)/include
DESTDIR := $(abspath $(DESTDIR))
DESTLIB = $(DESTDIR)$(libdir)
DESTBIN = $(DESTDIR)$(bindir)
DESTINC = $(DESTDIR)$(includedir)
BUILDDIR := build
BUILDINC = $(BUILDDIR)/usr/include
# Use multiarch lib directory in build
ifeq ($(MULTIARCH_DIR),)
BUILDLIB = $(BUILDDIR)/usr/lib
else
BUILDLIB = $(BUILDDIR)/usr/lib/$(MULTIARCH_DIR)
endif
BUILDBIN = $(BUILDDIR)/usr/bin
BUILDETCDIR = $(BUILDDIR)/etc
BUILDMODDIR = $(BUILDDIR)/lib/modules
# Support for multiple kernel versions and custom KDIR
KVER ?= $(shell uname -r)
KDIR ?= /lib/modules/$(KVER)/build
LIB_MAJOR_VER ?= $(shell awk '/\#define GDR_API_MAJOR_VERSION/ { print $$3 }' include/mtgdrapi.h | tr -d '\n')
LIB_MINOR_VER ?= $(shell awk '/\#define GDR_API_MINOR_VERSION/ { print $$3 }' include/mtgdrapi.h | tr -d '\n')
GDRAPI_ARCH := $(shell ./config_arch)
GDRAPI_INC := ../include
# Package version for DEB packages
# Note: libgdrapi is version 1.0.0, mtgdrdrv is version 0.1.0
LIB_VER ?= 1.0.0
KMOD_VER ?= 0.1.0
TESTS_VER ?= 0.1.0
META_VER ?= 1.0.0
RPM_RELEASE ?= 1
LIB_BASENAME:=libgdrapi.so
LIB_SONAME:=$(LIB_BASENAME).$(LIB_MAJOR_VER)
LIB_DYNAMIC=$(LIB_BASENAME).$(LIB_MAJOR_VER).$(LIB_MINOR_VER)
all: config driver lib exes
version:
@ echo "$(LIB_VER)"
config:
@ echo "GDRAPI_ARCH=$(GDRAPI_ARCH)"
driver:
cd src/gdrdrv && \
KVER=$(KVER) KDIR=$(KDIR) $(MAKE) $(MAKE_PARAMS)
lib:
cd src && \
$(MAKE) LIB_MAJOR_VER=$(LIB_MAJOR_VER) LIB_MINOR_VER=$(LIB_MINOR_VER)
exes: lib
cd tests && \
$(MAKE)
install: lib_install exes_install drv_install
lib_install: lib
@ echo "installing in $(DESTLIB) $(DESTINC)..." && \
mkdir -p $(DESTLIB) && \
install -D -v -m u=rwx,g=rx,o=rx src/$(LIB_DYNAMIC) -t $(DESTLIB) && \
mkdir -p $(DESTINC) && \
install -D -v -m u=rw,g=rw,o=r include/* -t $(DESTINC); \
cd $(DESTLIB); \
ln -sf $(LIB_DYNAMIC) $(LIB_SONAME); \
ln -sf $(LIB_SONAME) $(LIB_BASENAME);
exes_install: exes
cd tests && $(MAKE) install DESTBIN=$(DESTBIN)
drv_install: driver
mkdir -p /lib/modules/$(KVER)/extra && \
cp src/gdrdrv/mtgdrdrv.ko /lib/modules/$(KVER)/extra/ && \
depmod -a
# Build target for creating a build directory with all necessary files
build: clean-build
@echo "Building legacy package..."
# Create directories for package contents
mkdir -p $(BUILDDIR)/usr/lib/$(DEB_LIBDIR)
mkdir -p $(BUILDDIR)/usr/include
mkdir -p $(BUILDDIR)/usr/src/mtgdrdrv-$(KMOD_VER)
mkdir -p $(BUILDDIR)/usr/share/doc/mtgdrcpy
# Copy library files
cp src/$(LIB_DYNAMIC) $(BUILDDIR)/usr/lib/$(DEB_LIBDIR)/
ln -sf $(LIB_DYNAMIC) $(BUILDDIR)/usr/lib/$(DEB_LIBDIR)/$(LIB_SONAME)
ln -sf $(LIB_DYNAMIC) $(BUILDDIR)/usr/lib/$(DEB_LIBDIR)/$(LIB_BASENAME)
# Copy header files
cp include/mtgdrapi.h $(BUILDDIR)/usr/include/
cp include/mtgdrconfig.h $(BUILDDIR)/usr/include/
# Copy kernel module source files
cp -r src/* $(BUILDDIR)/usr/src/mtgdrdrv-$(KMOD_VER)/
cp packages/dkms.conf $(BUILDDIR)/usr/src/mtgdrdrv-$(KMOD_VER)/
cp packages/mtgdrdrv.conf $(BUILDDIR)/usr/src/mtgdrdrv-$(KMOD_VER)/
# Copy documentation
cp LICENSE $(BUILDDIR)/usr/share/doc/mtgdrcpy/copyright
# Create DEBIAN directory for package control files
mkdir -p $(BUILDDIR)/DEBIAN
# Copy DEBIAN control files from DEBIAN-lib directory
cp -r packages/DEBIAN-lib/* $(BUILDDIR)/DEBIAN/
# Replace version placeholder with actual version
sed -i "s/1.0.0/$(LIB_VER)/g" $(BUILDDIR)/DEBIAN/control
sed -i "s/@DEB_ARCH@/$(DEB_ARCH)/g" $(BUILDDIR)/DEBIAN/control
# Replace version in postinst and prerm scripts
sed -i "s/1.0.0/$(LIB_VER)/g" $(BUILDDIR)/DEBIAN/postinst
sed -i "s/1.0.0/$(LIB_VER)/g" $(BUILDDIR)/DEBIAN/prerm
# Make scripts executable
chmod 755 $(BUILDDIR)/DEBIAN/postinst
chmod 755 $(BUILDDIR)/DEBIAN/prerm
# New build targets for split packages
build-kmod: clean-build-kmod
@echo "Building kernel module package structure..."
@echo "Building for architecture: $(ARCH)"
@echo "Using libdir: $(libdir)"
# Create DKMS source directory for kernel module package
mkdir -p $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv
cp -r src/gdrdrv/* $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv
mkdir $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/scripts
cp scripts/test_gdrdrv_HAVE_PROC_OPS.sh $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/scripts
cp scripts/test_gdrdrv_HAVE_VM_FLAGS_SET.sh $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/scripts
cp scripts/test_gdrdrv_HAVE_CLASS_CREATE_WITH_OWNER.sh $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/scripts
cp scripts/test_gdrdrv_HAVE_CONST_DEV_UEVENT.sh $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/scripts
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/*.o
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/*.mod
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/*.ko
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/*.mod.c
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/*.symvers
rm -f $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/modules.order
rm -rf $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/src/gdrdrv/scripts
# Copy Makefile for DKMS build process
cp packages/dkms/Makefile $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/
# Create dkms.conf file for DKMS
cp packages/dkms.conf $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/
# Replace version placeholder in dkms.conf
sed -i "s/@FULL_VERSION@/$(KMOD_VER)/g" $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/dkms.conf
sed -i "s/@VERSION@/$(KMOD_VER)/g" $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/dkms.conf
sed -i "s|@MODULE_LOCATION@|/extra|g" $(BUILDDIR)/kmod/usr/src/mtgdrdrv-$(KMOD_VER)/dkms.conf
# Install module options configuration
mkdir -p $(BUILDDIR)/kmod/etc/modprobe.d
cp packages/mtgdrdrv.conf $(BUILDDIR)/kmod/etc/modprobe.d/mtgdrdrv.conf
# Add new functionality - prepare files for DKMS package
# Create DEBIAN directory for package control files
mkdir -p $(BUILDDIR)/kmod/DEBIAN
# Copy DEBIAN control files from DEBIAN-kmod directory
cp -r packages/DEBIAN-kmod/* $(BUILDDIR)/kmod/DEBIAN/
# Replace version placeholder in control file
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/kmod/DEBIAN/control
# Set architecture in control file based on ARCH parameter
sed -i "s/@DEB_ARCH@/$(DEB_ARCH)/g" $(BUILDDIR)/kmod/DEBIAN/control
# Replace version in postinst script
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/kmod/DEBIAN/postinst
# Replace version in prerm script
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/kmod/DEBIAN/prerm
# Set proper permissions for maintainer scripts
chmod 755 $(BUILDDIR)/kmod/DEBIAN/postinst
chmod 755 $(BUILDDIR)/kmod/DEBIAN/prerm
build-lib: clean-build-lib lib
@echo "Building lib package..."
# Create directories for package contents
mkdir -p $(BUILDDIR)/lib/usr/lib/$(DEB_LIBDIR)
mkdir -p $(BUILDDIR)/lib/usr/include
mkdir -p $(BUILDDIR)/lib/usr/share/doc/libgdrapi
# Copy library files
cp src/$(LIB_DYNAMIC) $(BUILDDIR)/lib/usr/lib/$(DEB_LIBDIR)/
ln -sf $(LIB_DYNAMIC) $(BUILDDIR)/lib/usr/lib/$(DEB_LIBDIR)/$(LIB_SONAME)
ln -sf $(LIB_DYNAMIC) $(BUILDDIR)/lib/usr/lib/$(DEB_LIBDIR)/$(LIB_BASENAME)
# Copy header files
cp include/mtgdrapi.h $(BUILDDIR)/lib/usr/include/
cp include/mtgdrconfig.h $(BUILDDIR)/lib/usr/include/
# Copy documentation
cp LICENSE $(BUILDDIR)/lib/usr/share/doc/libgdrapi/copyright
# Create DEBIAN directory for package control files
mkdir -p $(BUILDDIR)/lib/DEBIAN
# Copy DEBIAN control files from DEBIAN-lib directory
cp -r packages/DEBIAN-lib/* $(BUILDDIR)/lib/DEBIAN/
# Replace version placeholder with actual version
sed -i "s/1.0.0/$(LIB_VER)/g" $(BUILDDIR)/lib/DEBIAN/control
sed -i "s/@DEB_ARCH@/$(DEB_ARCH)/g" $(BUILDDIR)/lib/DEBIAN/control
# Make scripts executable
chmod 755 $(BUILDDIR)/lib/DEBIAN/postinst
chmod 755 $(BUILDDIR)/lib/DEBIAN/prerm
build-tests: clean-build-tests
@echo "Building test utilities package structure..."
@echo "Building for architecture: $(ARCH)"
@echo "Using libdir: $(libdir)"
mkdir -p $(BUILDDIR)/tests/usr/src/mtgdrcopy
# Copy tests directory
cp -r tests $(BUILDDIR)/tests/usr/src/mtgdrcopy/
# Remove build artifacts from tests directory
find $(BUILDDIR)/tests/usr/src/mtgdrcopy/tests -name "*.o" -delete
find $(BUILDDIR)/tests/usr/src/mtgdrcopy/tests -name "mtgdrcopy_*" -delete
find $(BUILDDIR)/tests/usr/src/mtgdrcopy/tests -path "*/testsuites/*.o" -delete
# Copy target environment Makefile from tests/package
cp tests/package/Makefile $(BUILDDIR)/tests/usr/src/mtgdrcopy/tests/
# Create README file with instructions
echo "This package contains test source files for GDRCopy." > $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
echo "To compile and run tests:" >> $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
echo "1. cd /usr/src/mtgdrcopy/tests" >> $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
echo "2. make" >> $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
echo "3. Run individual test binaries with appropriate permissions" >> $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
echo "Note: Make sure you have installed the libgdrapi package before compiling." >> $(BUILDDIR)/tests/usr/src/mtgdrcopy/README.md
# Create DEBIAN directory for package control files
mkdir -p $(BUILDDIR)/tests/DEBIAN
# Copy DEBIAN control files from DEBIAN-tests directory
cp -r packages/DEBIAN-tests/* $(BUILDDIR)/tests/DEBIAN/
# Replace version placeholder in control file
sed -i "s/0.1.0/$(LIB_VER)/g" $(BUILDDIR)/tests/DEBIAN/control
# Set architecture in control file based on ARCH parameter
sed -i "s/@DEB_ARCH@/$(DEB_ARCH)/g" $(BUILDDIR)/tests/DEBIAN/control
# Replace version in postinst script
sed -i "s/0.1.0/$(LIB_VER)/g" $(BUILDDIR)/tests/DEBIAN/postinst
# Replace version in prerm script
sed -i "s/0.1.0/$(LIB_VER)/g" $(BUILDDIR)/tests/DEBIAN/prerm
# Set proper permissions for maintainer scripts
chmod 755 $(BUILDDIR)/tests/DEBIAN/postinst
chmod 755 $(BUILDDIR)/tests/DEBIAN/prerm
build-meta: clean-build-meta
@echo "Building meta package structure..."
mkdir -p $(BUILDDIR)/meta/DEBIAN
# Copy DEBIAN control files
cp -r packages/DEBIAN-meta/* $(BUILDDIR)/meta/DEBIAN/
# Replace version placeholder in control file
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/meta/DEBIAN/control
# Set architecture in control file based on ARCH parameter
if [ "$(ARCH)" = "x86_64" ]; then \
sed -i "s/^Architecture:.*/Architecture: amd64/" $(BUILDDIR)/meta/DEBIAN/control; \
elif [ "$(ARCH)" = "aarch64" ] || [ "$(ARCH)" = "arm64" ]; then \
sed -i "s/^Architecture:.*/Architecture: arm64/" $(BUILDDIR)/meta/DEBIAN/control; \
else \
sed -i "s/^Architecture:.*/Architecture: $(ARCH)/" $(BUILDDIR)/meta/DEBIAN/control; \
fi
# Replace version in postinst script
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/meta/DEBIAN/postinst
# Replace version in prerm script
sed -i "s/0.1.0/$(KMOD_VER)/g" $(BUILDDIR)/meta/DEBIAN/prerm
# Set proper permissions for maintainer scripts
chmod 755 $(BUILDDIR)/meta/DEBIAN/postinst
chmod 755 $(BUILDDIR)/meta/DEBIAN/prerm
deb: build
@echo "Creating DEB package..."
@scripts/create_deb_package.sh
deb-bundle: deb-all
@echo "Creating DEB bundle package..."
@scripts/create_deb_bundle.sh
# New packaging targets for split packages
deb-kmod: build-kmod
@echo "Creating kernel module DEB package..."
@scripts/create_kmod_deb_package.sh
mkdir -p $(BUILDDIR)
mv $(BUILDDIR)/../mtgdrdrv-dkms_$(KMOD_VER)_$(DEB_ARCH).deb $(BUILDDIR)/
deb-lib: build-lib
@echo "Creating API library DEB package..."
@scripts/create_lib_deb_package.sh
mkdir -p $(BUILDDIR)
mv $(BUILDDIR)/../libgdrapi_$(LIB_VER)_$(DEB_ARCH).deb $(BUILDDIR)/
deb-tests: build-tests
@echo "Creating test utilities DEB package..."
@scripts/create_tests_deb_package.sh
mkdir -p $(BUILDDIR)
mv $(BUILDDIR)/../mtgdrcopy-tests_$(KMOD_VER)_$(DEB_ARCH).deb $(BUILDDIR)/
deb-meta: build-meta
@echo "Building meta package..."
@scripts/create_meta_deb_package.sh
mkdir -p $(BUILDDIR)
mv $(BUILDDIR)/../mtgdrcopy_$(META_VER)_all.deb $(BUILDDIR)/
# Combined target to build all packages
deb-all: deb-kmod deb-lib deb-tests deb-meta
@echo "All DEB packages created successfully"
check-rpm-tools:
@command -v rpmbuild >/dev/null 2>&1 || { \
echo "Error: rpmbuild is required to build RPM packages."; \
echo "On Ubuntu, install it with: sudo apt install rpm"; \
exit 1; \
}
rpm-kmod: check-rpm-tools build-kmod
@echo "Creating kernel module RPM package..."
@scripts/create_kmod_rpm_package.sh $(RPM_ARCH) $(KMOD_VER) $(RPM_RELEASE)
rpm-lib: check-rpm-tools build-lib
@echo "Creating API library RPM package..."
@scripts/create_lib_rpm_package.sh $(RPM_ARCH) $(LIB_VER) $(RPM_RELEASE)
rpm-tests: check-rpm-tools build-tests
@echo "Creating test utilities RPM package..."
@scripts/create_tests_rpm_package.sh $(RPM_ARCH) $(TESTS_VER) $(RPM_RELEASE) $(LIB_VER)
rpm-meta: check-rpm-tools build-meta
@echo "Creating meta RPM package..."
@scripts/create_meta_rpm_package.sh noarch $(META_VER) $(RPM_RELEASE) $(KMOD_VER) $(LIB_VER) $(TESTS_VER)
rpm-all: rpm-kmod rpm-lib rpm-tests rpm-meta
@echo "All RPM packages created successfully"
clean-build:
rm -rf $(BUILDDIR)
clean-build-kmod:
rm -rf $(BUILDDIR)/kmod
clean-build-lib:
rm -rf $(BUILDDIR)/lib
clean-lib-build:
rm -rf $(BUILDDIR)/lib
clean-build-tests:
rm -rf $(BUILDDIR)/tests
clean-build-meta:
rm -rf $(BUILDDIR)/meta
clean:
cd tests && \
$(MAKE) clean
cd src && \
$(MAKE) clean
cd src/gdrdrv && \
$(MAKE) clean
rm -rf $(BUILDDIR)