File: declspec.sh

package info (click to toggle)
libgadu 1:1.12.1-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,820 kB
  • ctags: 1,649
  • sloc: ansic: 21,459; perl: 370; makefile: 209; sh: 124
file content (9 lines) | stat: -rwxr-xr-x 350 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
#!/bin/sh
# $Id$

# this script if for converting libgadu.h file to be used with MSVC

cat $1 \
	| sed -e "s/^[a-z][a-z0-9_ *]\+gg_[a-z0-9_]\+(.*/__declspec(dllimport) \0/g"\
	| sed -e "s/^extern [a-z][a-z0-9_ *]\+gg_[a-z0-9_]\+;.*/__declspec(dllimport) \0/g"\
	| sed -e "s/^extern [a-z][a-z0-9_ *]\+(\*gg_[a-z0-9_]\+)(.*/__declspec(dllimport) \0/g"