0

I am currently following a guide to install Java 1.4 on the CentOS site and was wondering if anyone could help me understand some of the terminology.

It states:

For this example, it will be assumed that the contents of ~/.rpmmacros includes:

%_topdir /home//rpmbuild

%_tmppath %{_topdir}/tmp

Remember to create the ~/rpmbuild/ tree if it has not been created yet, but be aware that your directory is not required to be named "rpmbuild" as in this example (consult your ~/.rpmmacros to know):

Where would ~/.rpmmacros be located and how would I ensure it contained the two lines beginning %?

Additionally how would I create the ~/.rpmbuild/ tree?

Larry B
  • 261
  • 4
  • 5
  • 18

2 Answers2

2

Where would ~/.rpmmacros be located...

In most Unix shells, ~ is an abbreviation for "your home directory". So ~/.rpmmacros is the file .rpmmacros in your home directory. The contents you have listed...

%_topdir /home//rpmbuild
%_tmppath %{_topdir}/tmp

...are problematic; that first line is meant to be the path to your home directory and should include your username. For example:

%_topdir /home/gharping/rpmbuild

...and how would I ensure it contained the two lines beginning %?

You would use your favorite text editor...like vim or emacs or gedit or something similar.

Additionally how would I create the ~/.rpmbuild/ tree?

You use the mkdir command to create directories. From within your home directory, you could run:

mkdir -p rpmbuild/tmp

...to create both the rpmbuild and rpmbuild/tmp/ directories.

larsks
  • 43,623
  • 14
  • 121
  • 180
-4

In my case(CentOS 6.4), I found the list of all macros inside /usr/lib/rpm/macros, just edit the file...