summaryrefslogtreecommitdiffstats
path: root/source-builder/config/microwindows-1.cfg
blob: d6cfab585f44744e19adfb7f73e4c1a27ebc8c2f (plain) (blame)
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
#
# microwindows
#
# This configuration file configure's, make's and install's microwindows.
#

%if %{release} == %{nil}
%define release 1
%endif

Name:      microwindows-v%{microwindows_version}-%{_host}-%{release}
Summary:   microwindows is an Open Source Window System
Version:   %{microwindows_version}
Release:   %{release}
URL:     http://www.microwindows.org/

#
# microwindows Source
#
%source set microwindows ftp://microwindows.censoft.com/pub/microwindows/microwindows-src-%{microwindows_version}.tar.gz

#
# Prepare the source code.
#
%prep
  build_top=$(pwd)

  source_dir_microwindows="microwin"
  %source setup microwindows -q -n microwin
  %patch setup microwindows -p1

  cd ${build_top}

#
# Build the source code.
#
%build
  build_top=$(pwd)

  %{build_directory}

  mkdir -p ${build_dir}/src
  cd ${build_dir}/src
  cp -r ${build_top}/${source_dir_microwindows}/src/* .

  #%{host_build_flags}

  export RTEMS_MAKEFILE_PATH=%{rtems_bsp_prefix}

  %{__make} -f Makefile.rtems CONFIG=`pwd`/Configs/config.rtems -k all

  cd ${build_top}

%install
  build_top=$(pwd)

  %{__rmdir} $SB_BUILD_ROOT

  cd ${build_dir}/src
  mkdir -p $SB_BUILD_ROOT/%{_includedir}
  mkdir -p $SB_BUILD_ROOT/%{_libdir}
  mkdir -p $SB_BUILD_ROOT/%{_bindir}
  cp -r include/* $SB_BUILD_ROOT/%{_includedir}
  cp -r lib/*.a $SB_BUILD_ROOT/%{_libdir}
  cp -r bin/* $SB_BUILD_ROOT/%{_bindir}