From: WonYoung Choi Date: Wed, 6 Jul 2016 08:36:38 +0000 (+0900) Subject: Change assembly installation path X-Git-Tag: submit/trunk/20170823.075128~103^2~35 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0c0202f6f70d5200c0fd28db7af9b8778835b3d7;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git Change assembly installation path The assembly installation path is changed to /usr/share/assembly/ as default. This path can be overrided by the macro %dotnet_assembly_path also. Change-Id: I4bdc2aca30dfeed39028a6d70497f06a7fa48a76 --- diff --git a/packaging/csapi-location.pc.in b/packaging/csapi-location.pc.in deleted file mode 100644 index 41b6556..0000000 --- a/packaging/csapi-location.pc.in +++ /dev/null @@ -1,5 +0,0 @@ -Name: csapi-location -Description: Tizen location API's for C# -Version: @version@ -Libs: -r:@dllpath@/@dllname@ -Requires: diff --git a/packaging/csapi-location.spec b/packaging/csapi-location.spec index baae27a..72930d6 100755 --- a/packaging/csapi-location.spec +++ b/packaging/csapi-location.spec @@ -1,7 +1,13 @@ +%{!?dotnet_assembly_path: %define dotnet_assembly_path %{_datadir}/assembly} + +%if 0%{?tizen_build_devel_mode} %define BUILDCONF Debug +%else +%define BUILDCONF Release +%endif Name: csapi-location -Summary: Tizen Location API's for C# +Summary: Tizen Location API for C# Version: 1.0.0 Release: 1 Group: Development/Libraries @@ -9,52 +15,46 @@ License: Apache-2.0 URL: https://www.tizen.org Source0: %{name}-%{version}.tar.gz Source1: %{name}.manifest -Source2: %{name}.pc.in +# Mono BuildRequires: mono-compiler BuildRequires: mono-devel -BuildRequires: pkgconfig(glib-2.0) -BuildRequires: pkgconfig(csapi-tizen) -Requires: glib-2.0 +# P/Invoke Build Requires +BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(capi-location-manager) -%description -Tizen API for C# - -%package devel -Summary: Development package for %{name} -Group: Development/Libraries -Requires: %{name} = %{version}-%{release} +# C# API Requires +BuildRequires: csapi-tizen -%description devel -Development package for %{name} +%description +Tizen Location API for C# %prep %setup -q - cp %{SOURCE1} . +%define Assemblies Tizen.Location + %build -# build dll -xbuild Tizen.Location/Tizen.Location.csproj /p:Configuration=%{BUILDCONF} +for ASM in %{Assemblies}; do +xbuild $ASM/$ASM.csproj \ + /p:Configuration=%{BUILDCONF} \ + /p:ReferencePath=%{dotnet_assembly_path} +done %install -gacutil -i Tizen.Location/bin/%{BUILDCONF}/Tizen.Location.dll -root "%{buildroot}%{_libdir}" -package tizen +# Assemblies +mkdir -p %{buildroot}%{dotnet_assembly_path} +for ASM in %{Assemblies}; do +install -p -m 644 $ASM/bin/%{BUILDCONF}/$ASM.dll %{buildroot}%{dotnet_assembly_path} +done -# generate pkgconfig -mkdir -p %{buildroot}%{_libdir}/pkgconfig -sed -e "s#@version@#%{version}#g" \ - -e "s#@dllpath@#%{dllpath}#g" \ - -e "s#@dllname@#%{dllname}#g" \ - %{SOURCE2} > %{buildroot}%{_libdir}/pkgconfig/%{name}.pc - -%post -gacutil -i %{dllpath}/%{dllname} +# License +mkdir -p %{buildroot}%{_datadir}/license +cp LICENSE %{buildroot}%{_datadir}/license/%{name} %files %manifest %{name}.manifest -%{_libdir}/mono/ - -%files devel -%{_libdir}/pkgconfig/%{name}.pc +%attr(644,root,root) %{dotnet_assembly_path}/*.dll +%attr(644,root,root) %{_datadir}/license/%{name} diff --git a/src/Tizen.Location/Tizen.Location.csproj b/src/Tizen.Location/Tizen.Location.csproj index d75d390..cac7938 100644 --- a/src/Tizen.Location/Tizen.Location.csproj +++ b/src/Tizen.Location/Tizen.Location.csproj @@ -1,5 +1,5 @@  - + Debug @@ -70,11 +70,9 @@ - csapi-tizen ..\..\tizen\Tizen\obj\Debug\Tizen.dll - csapi-tizen ..\..\tizen\Tizen.Internals\bin\Debug\Tizen.Internals.dll @@ -89,9 +87,9 @@ Tizen True - + -