File: rules

package info (click to toggle)
crossguid 0.0%2Bgit200150803-2
  • links: PTS
  • area: main
  • in suites: stretch
  • size: 236 kB
  • sloc: cpp: 321; xml: 48; sh: 28; makefile: 19; java: 18
file content (27 lines) | stat: -rwxr-xr-x 873 bytes parent folder | download
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
#!/usr/bin/make -f

INSTDIRS = debian/tmp/usr/include debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)

%:
	dh $@ 

override_dh_auto_build:
	$(CXX) -shared -fPIC -Wall -std=c++11 -Wl,-soname,libcrossguid.so.0 -DGUID_LIBUUID \
	-I/usr/include/uuid  guid.cpp -o libcrossguid.so.0.0.1 $(CPPFLAGS) $(CXXFLAGS) -luuid \
	$(LDFLAGS)
	ar x /usr/lib/$(DEB_HOST_MULTIARCH)/libuuid.a
	ar cr libcrossguid.a *.o

override_dh_auto_install: $(INSTDIRS)
	cp guid.h debian/tmp/usr/include/
	cp libcrossguid.* debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/

override_dh_link:
	dh_link -plibcrossguid-dev usr/lib/$(DEB_HOST_MULTIARCH)/libcrossguid.so.0.0.1 usr/lib/$(DEB_HOST_MULTIARCH)/libcrossguid.so
	dh_link -plibcrossguid0 usr/lib/$(DEB_HOST_MULTIARCH)/libcrossguid.so.0.0.1 usr/lib/$(DEB_HOST_MULTIARCH)/libcrossguid.so.0

$(INSTDIRS):
	mkdir -p $@

override_dh_clean:
	dh_clean libcrossguid.* *.o